File tree Expand file tree Collapse file tree 14 files changed +23
-15
lines changed Expand file tree Collapse file tree 14 files changed +23
-15
lines changed Original file line number Diff line number Diff line change 1212 <BundleTestAndroidAppDependsOn >AndroidBuild</BundleTestAndroidAppDependsOn >
1313 </PropertyGroup >
1414
15- <PropertyGroup Condition =" '$(RuntimeFlavor)' == 'CoreCLR' and '$(IsFunctionalTest )' != 'true '" >
15+ <PropertyGroup Condition =" '$(RuntimeFlavor)' == 'CoreCLR' and '$(ReferenceXUnitWrapperGenerator )' != 'false '" >
1616 <DefineConstants >$(DefineConstants);SINGLE_FILE_TEST_RUNNER</DefineConstants >
1717 </PropertyGroup >
1818
Original file line number Diff line number Diff line change 3232 <SelfContained >true</SelfContained >
3333 </PropertyGroup >
3434
35- <PropertyGroup Condition =" ('$(PublishSingleFile)' == 'true' or '$(TestNativeAot)' == 'true') and '$(IsFunctionalTest )' != 'true '" >
35+ <PropertyGroup Condition =" ('$(PublishSingleFile)' == 'true' or '$(TestNativeAot)' == 'true') and '$(ReferenceXUnitWrapperGenerator )' != 'false '" >
3636 <DefineConstants >$(DefineConstants);SINGLE_FILE_TEST_RUNNER</DefineConstants >
3737 </PropertyGroup >
3838
4444
4545 <ItemGroup Condition =" '$(TestNativeAot)' == 'true'" >
4646 <RdXmlFile Include =" $(MSBuildThisFileDirectory)default.rd.xml" />
47- <TrimmerRootAssembly Include =" TestUtilities" />
47+ <TrimmerRootAssembly Include =" TestUtilities" Condition = " '$(SkipTestUtilitiesReference)' != 'true' " />
4848 </ItemGroup >
4949
5050 <ItemGroup >
5151 <Compile Include =" $(CommonTestPath)SingleFileTestRunner\SingleFileTestRunner.cs"
5252 Link =" Common\SingleFileTestRunner\SingleFileTestRunner.cs"
53- Condition =" '$(IsFunctionalTest )' != 'true '" />
53+ Condition =" '$(ReferenceXUnitWrapperGenerator )' != 'false '" />
5454 </ItemGroup >
5555
5656 <ItemGroup >
Original file line number Diff line number Diff line change 215215 <ImportProjectExtensionTargets >false</ImportProjectExtensionTargets >
216216 </PropertyGroup >
217217
218- <PropertyGroup Condition =" '$(TargetOS)' == 'ios' or '$(TargetOS)' == 'tvos'" >
218+ <PropertyGroup Condition =" '$(TargetOS)' == 'ios' or '$(TargetOS)' == 'tvos' or ('$(TargetOS)' == 'android' and '$(TestBuildMode)' == 'nativeaot') " >
219219 <EnableAggressiveTrimming Condition =" '$(OutputType)' == 'Exe'" >true</EnableAggressiveTrimming >
220220 <PublishTrimmed Condition =" '$(OutputType)' == 'Exe'" >true</PublishTrimmed >
221221 <SkipTestUtilitiesReference >true</SkipTestUtilitiesReference >
235235 <HybridGlobalization Condition =" '$(_IsApplePlatform)' == 'true'" >true</HybridGlobalization >
236236 </PropertyGroup >
237237
238+ <PropertyGroup Condition =" '$(TargetOS)' == 'android' and '$(TestBuildMode)' == 'nativeaot'" >
239+ <NativeLib >shared</NativeLib >
240+ <CustomNativeMain >true</CustomNativeMain >
241+ </PropertyGroup >
242+
238243 <Import Project =" $(RepositoryEngineeringDir)testing\tests.props" Condition =" '$(IsTestsCommonProject)' != 'true'" />
239244 <Import Project =" $(BaseOutputPath)\packages\Common\test_dependencies\test_dependencies\test_dependencies.*.props" Condition =" '$(IsTestsCommonProject)' != 'true'" />
240245</Project >
Original file line number Diff line number Diff line change 456456
457457
458458 <PropertyGroup >
459- <DisableImplicitFrameworkReferences >true</DisableImplicitFrameworkReferences >
459+ <DisableImplicitFrameworkReferences Condition = " '$(DisableImplicitFrameworkReferences)' == '' " >true</DisableImplicitFrameworkReferences >
460460 </PropertyGroup >
461461
462462 <PropertyGroup >
508508 <Import Project =" $(RepositoryEngineeringDir)toolAot.targets" />
509509 <Import Project =" $(MSBuildProjectFullPath).targets" Condition =" Exists('$(MSBuildProjectFullPath).targets')" />
510510 <Import Project =" $(RepoRoot)/src/tests/Common/mergedrunner.targets" Condition =" '$(IsMergedTestRunnerAssembly)' == 'true'" />
511+ <Import Project =" $(RepositoryEngineeringDir)testing\tests.targets" Condition =" '$(TargetsAndroid)' == 'true'" />
511512
512513 <Target Name =" GetBinPlaceTargetFramework" />
513514
Original file line number Diff line number Diff line change 55 <PropertyGroup >
66 <!-- We expect trimming to be fully enabled in these tests -->
77 <EnableAggressiveTrimming >true</EnableAggressiveTrimming >
8+ <!-- We need the library import generator when running android tests. -->
9+ <DisableImplicitFrameworkReferences >false</DisableImplicitFrameworkReferences >
810 </PropertyGroup >
911</Project >
Original file line number Diff line number Diff line change 99class Program
1010{
1111 [ Method ]
12- static int Main ( )
12+ public static int Main ( string [ ] args )
1313 {
1414 // Sanity check: we don't currently expect attributes on types to be optimized away
1515 if ( GetTypeSecretly ( nameof ( TypeAttribute ) ) == null )
Original file line number Diff line number Diff line change @@ -30,7 +30,7 @@ unsafe class ControlFlowGuardTests
3030
3131 static bool s_armed ;
3232
33- static int Main ( string [ ] args )
33+ public static int Main ( string [ ] args )
3434 {
3535 // Are we running the control program?
3636 if ( args . Length == 0 )
Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ public BringUpTest()
2424
2525 static int finallyCounter = 0 ;
2626
27- public static int Main ( )
27+ public static int Main ( string [ ] args )
2828 {
2929 // This test also doubles as server GC test
3030 if ( ! System . Runtime . GCSettings . IsServerGC )
Original file line number Diff line number Diff line change 99
1010unsafe class Program
1111{
12- static int Main ( )
12+ public static int Main ( string [ ] args )
1313 {
1414 s_success = true ;
1515
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ public class ReflectionTest
1111 const int Pass = 100 ;
1212 const int Fail = - 1 ;
1313
14- public static int Main ( )
14+ public static int Main ( string [ ] args )
1515 {
1616 if ( TestStaticBases ( ) == Fail )
1717 return Fail ;
You can’t perform that action at this time.
0 commit comments