Fix Globalization tests (#72653)
authorLakshan Fernando <lakshanf@hotmail.com>
Fri, 22 Jul 2022 16:05:57 +0000 (09:05 -0700)
committerGitHub <noreply@github.com>
Fri, 22 Jul 2022 16:05:57 +0000 (09:05 -0700)
* Fix Globalization tests

* enable test in rolling runs

src/libraries/System.Globalization/tests/System.Globalization.Tests.csproj
src/libraries/System.Globalization/tests/default.rd.xml [new file with mode: 0644]
src/libraries/tests.proj

index 5f13580..f570f26 100644 (file)
@@ -7,6 +7,9 @@
     <UnicodeUcdVersion>14.0</UnicodeUcdVersion>
   </PropertyGroup>
   <ItemGroup>
+    <RdXmlFile Include="default.rd.xml" />
+  </ItemGroup>
+  <ItemGroup>
     <Compile Include="AssemblyInfo.cs" />
     <Compile Include="IcuTests.cs" />
     <Compile Include="CompareInfo\CompareInfoTests.cs" />
diff --git a/src/libraries/System.Globalization/tests/default.rd.xml b/src/libraries/System.Globalization/tests/default.rd.xml
new file mode 100644 (file)
index 0000000..22d6327
--- /dev/null
@@ -0,0 +1,15 @@
+<Directives>
+  <Application>
+    <Assembly Name="System.Linq">
+      <!-- called by xUnit in obscure MemberData scenarios  -->
+      <Type Name="System.Linq.Enumerable">
+        <Method Name="Cast" Dynamic="Required All">
+          <GenericArgument Name="System.Globalization.UnicodeCategory,System.Globalization" />
+        </Method>
+        <Method Name="ToArray" Dynamic="Required All">
+          <GenericArgument Name="System.Globalization.UnicodeCategory,System.Globalization" />
+        </Method>
+      </Type>
+    </Assembly>    
+  </Application>
+</Directives>
index 5de1a0d..9fc4c0c 100644 (file)
     <ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Drawing.Primitives\tests\System.Drawing.Primitives.Tests.csproj" />
     <ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Dynamic.Runtime\tests\System.Dynamic.Runtime.Tests.csproj" />
     <ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Formats.Cbor\tests\System.Formats.Cbor.Tests.csproj" />
-    <ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Globalization\tests\System.Globalization.Tests.csproj" />
     <ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Globalization\tests\NlsTests\System.Globalization.Nls.Tests.csproj" />
     <ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Globalization.Calendars\tests\CalendarTestWithConfigSwitch\System.Globalization.CalendarsWithConfigSwitch.Tests.csproj" />
     <ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Linq.Queryable\tests\System.Linq.Queryable.Tests.csproj" />