Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/guiunit.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarius Ungureanu <maungu@microsoft.com>2021-02-26 00:37:12 +0300
committerMarius Ungureanu <maungu@microsoft.com>2021-02-26 00:37:12 +0300
commit0d905e12ee4336a428fe021805c3fb3b0f3c59e6 (patch)
treed32a30f345e598769d308fd446419de192a82ec9
parent9affe4813987b009022ab7b10e55f81f4a37344c (diff)
Add some more markers where ExitCode should be set to non-zero
-rw-r--r--src/framework/GuiUnit/MonoMacMainLoopIntegration.cs1
-rw-r--r--src/framework/GuiUnit/TestRunner.cs2
2 files changed, 3 insertions, 0 deletions
diff --git a/src/framework/GuiUnit/MonoMacMainLoopIntegration.cs b/src/framework/GuiUnit/MonoMacMainLoopIntegration.cs
index 6774694..6ff8100 100644
--- a/src/framework/GuiUnit/MonoMacMainLoopIntegration.cs
+++ b/src/framework/GuiUnit/MonoMacMainLoopIntegration.cs
@@ -33,6 +33,7 @@ namespace GuiUnit
var errPtr = dlerror ();
var errStr = (errPtr == IntPtr.Zero)? "<unknown error>" : Marshal.PtrToStringAnsi (errPtr);
Console.WriteLine ("WARNING: Cannot load {0}: {1}", dylibPath, errStr);
+ throw new InvalidOperationException("Unable to initialize Xamarin.Mac");
}
var initMethod = Application.GetMethod ("Init", System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.Static);
diff --git a/src/framework/GuiUnit/TestRunner.cs b/src/framework/GuiUnit/TestRunner.cs
index 3950cf3..0e921be 100644
--- a/src/framework/GuiUnit/TestRunner.cs
+++ b/src/framework/GuiUnit/TestRunner.cs
@@ -238,6 +238,7 @@ namespace GuiUnit
catch (FileNotFoundException ex)
{
writer.WriteLine(ex.Message);
+ ExitCode = 1;
}
catch (Exception ex)
{
@@ -272,6 +273,7 @@ namespace GuiUnit
BeforeShutdown (null, EventArgs.Empty);
} catch (Exception ex) {
Console.WriteLine ("Unexpected error during `BeforeShutdown`: {0}", ex);
+ ExitCode = 1;
} finally {
MainLoop.Shutdown ();
}