From 2f321f08e49dda6b329469ac19662b56f0243ad4 Mon Sep 17 00:00:00 2001 From: Egor Bogatov Date: Sun, 31 May 2020 16:28:47 +0300 Subject: [PATCH] [mono] Enable parallel mode for xunit on Android by default (#37058) --- src/libraries/Common/tests/AndroidTestRunner/AndroidTestRunner.cs | 3 ++- src/libraries/System.Runtime/tests/System/Type/TypePropertyTests.cs | 2 +- .../tasks/mobile.tasks/AndroidAppBuilder/Templates/runtime-android.c | 5 +++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/libraries/Common/tests/AndroidTestRunner/AndroidTestRunner.cs b/src/libraries/Common/tests/AndroidTestRunner/AndroidTestRunner.cs index 1360ad0..f099fcf 100644 --- a/src/libraries/Common/tests/AndroidTestRunner/AndroidTestRunner.cs +++ b/src/libraries/Common/tests/AndroidTestRunner/AndroidTestRunner.cs @@ -30,7 +30,8 @@ public class SimpleAndroidTestRunner : AndroidApplicationEntryPoint, IDevice } int exitCode = 0; s_MainTestName = Path.GetFileNameWithoutExtension(s_testLibs[0]); - var simpleTestRunner = new SimpleAndroidTestRunner(true); + string? verbose = Environment.GetEnvironmentVariable("XUNIT_VERBOSE")?.ToLower(); + var simpleTestRunner = new SimpleAndroidTestRunner(verbose == "true" || verbose == "1"); simpleTestRunner.TestsCompleted += (e, result) => { if (result.FailedTests > 0) diff --git a/src/libraries/System.Runtime/tests/System/Type/TypePropertyTests.cs b/src/libraries/System.Runtime/tests/System/Type/TypePropertyTests.cs index fc683bd..a821952 100644 --- a/src/libraries/System.Runtime/tests/System/Type/TypePropertyTests.cs +++ b/src/libraries/System.Runtime/tests/System/Type/TypePropertyTests.cs @@ -195,6 +195,7 @@ namespace System.Tests.Types } [Fact] + [ActiveIssue("https://github.com/dotnet/runtime/issues/31713", TestRuntimes.Mono)] public void IsByRef_Get_ReturnsExpected() { Type t = CreateType(); @@ -531,7 +532,6 @@ namespace System.Tests.Types public override Type BaseType => typeof(ValueType); } - [ActiveIssue("https://github.com/dotnet/runtime/issues/31713", TestRuntimes.Mono)] public class VoidTests : StructTypeTestBase { public override Type CreateType() => typeof(void); diff --git a/tools-local/tasks/mobile.tasks/AndroidAppBuilder/Templates/runtime-android.c b/tools-local/tasks/mobile.tasks/AndroidAppBuilder/Templates/runtime-android.c index 4a2af6a..871708c 100644 --- a/tools-local/tasks/mobile.tasks/AndroidAppBuilder/Templates/runtime-android.c +++ b/tools-local/tasks/mobile.tasks/AndroidAppBuilder/Templates/runtime-android.c @@ -139,8 +139,9 @@ mono_mobile_runtime_init (void) { // uncomment for debug output: // - // setenv ("MONO_LOG_LEVEL", "debug", TRUE); - // setenv ("MONO_LOG_MASK", "all", TRUE); + // setenv ("XUNIT_VERBOSE", "true", true); + // setenv ("MONO_LOG_LEVEL", "debug", true); + // setenv ("MONO_LOG_MASK", "all", true); bool wait_for_debugger = false; chdir (bundle_path); -- 2.7.4