Skip to content

Commit f8b58d8

Browse files
authored
[Android] Enable System.Runtime.Loader tests on CoreCLR Android (#117713)
* Run failing tests * Disable failing tests
1 parent f1a3a0f commit f8b58d8

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

src/libraries/System.Runtime.Loader/tests/LoaderLinkTest.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ namespace LoaderLinkTest
1313
{
1414
public class LoaderLinkTest
1515
{
16-
[Fact]
16+
[ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.HasAssemblyFiles))]
1717
public static void EnsureTypesLinked() // https://github.com/dotnet/runtime/issues/42207
1818
{
1919
string parentDir = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);

src/libraries/System.Runtime.Loader/tests/SatelliteAssemblies.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ public static IEnumerable<object[]> MainResources_TestData()
7474
}
7575
}
7676

77-
[Theory]
77+
[ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.HasAssemblyFiles))]
7878
[MemberData(nameof(MainResources_TestData))]
7979
public static void mainResources(string lang, string expected)
8080
{
@@ -131,7 +131,7 @@ public static IEnumerable<object[]> DescribeLib_TestData()
131131
yield return new object[] { "ReferencedClassLibNeutralIsSatellite", "ReferencedClassLibNeutralIsSatellite.Program, ReferencedClassLibNeutralIsSatellite", "es", "Neutral (es) language ReferencedClassLibNeutralIsSatellite description 1.0.0" };
132132
}
133133

134-
[ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization))]
134+
[ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.HasAssemblyFiles))]
135135
[MemberData(nameof(DescribeLib_TestData))]
136136
public void describeLib(string alc, string type, string culture, string expected)
137137
{
@@ -187,7 +187,7 @@ public static IEnumerable<object[]> SatelliteLoadsCorrectly_TestData()
187187
yield return new object[] { "ReferencedClassLibNeutralIsSatellite", "ReferencedClassLibNeutralIsSatellite", "es" };
188188
}
189189

190-
[ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization))]
190+
[ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.HasAssemblyFiles))]
191191
[MemberData(nameof(SatelliteLoadsCorrectly_TestData))]
192192
public void SatelliteLoadsCorrectly_FromName(string alc, string assemblyName, string culture)
193193
{
@@ -207,8 +207,8 @@ public void SatelliteLoadsCorrectly_FromName(string alc, string assemblyName, st
207207

208208
Assert.Equal(culture, satelliteAssembly.GetName().CultureName);
209209
}
210-
211-
[ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization))]
210+
211+
[ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.HasAssemblyFiles))]
212212
[MemberData(nameof(SatelliteLoadsCorrectly_TestData))]
213213
public void SatelliteLoadsCorrectly_FromPath(string alc, string assemblyName, string culture)
214214
{

src/libraries/tests.proj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -228,13 +228,13 @@
228228
<!-- https://github.com/dotnet/runtime/issues/114951 -->
229229
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Net.Http\tests\FunctionalTests\System.Net.Http.Functional.Tests.csproj" />
230230
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Diagnostics.DiagnosticSource\tests\TestWithConfigSwitches\System.Diagnostics.DiagnosticSource.Switches.Tests.csproj" />
231-
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Reflection.MetadataLoadContext\tests\System.Reflection.MetadataLoadContext.Tests.csproj" />
232231
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Runtime\tests\System.Resources.ResourceManager.Tests\System.Resources.ResourceManager.Tests.csproj" />
233232
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Runtime\tests\System.Runtime.Tests\InvariantTimezone\System.Runtime.InvariantTimezone.Tests.csproj" />
234-
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Runtime.Loader\tests\System.Runtime.Loader.Tests.csproj" />
235233
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Runtime\tests\System.Text.Encoding.Tests\System.Text.Encoding.Tests.csproj" />
236234
<!-- https://github.com/dotnet/runtime/issues/62547 -->
237235
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Security.Cryptography\tests\System.Security.Cryptography.Tests.csproj" />
236+
<!-- https://github.com/dotnet/runtime/issues/72908 -->
237+
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Reflection.MetadataLoadContext\tests\System.Reflection.MetadataLoadContext.Tests.csproj" />
238238
</ItemGroup>
239239

240240
<ItemGroup Condition="'$(TargetOS)' == 'android' and '$(TargetArchitecture)' == 'x64' and '$(RuntimeFlavor)' == 'CoreCLR' and '$(RunDisablediOSTests)' != 'true'">

0 commit comments

Comments
 (0)