From 0b01be241cca70ef1bf36bf38257b373c0aba136 Mon Sep 17 00:00:00 2001 From: Marek Safar Date: Wed, 30 May 2012 19:03:51 +0100 Subject: [PATCH] Improve failing test --- mcs/class/corlib/Test/System.Threading/ThreadTest.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/mcs/class/corlib/Test/System.Threading/ThreadTest.cs b/mcs/class/corlib/Test/System.Threading/ThreadTest.cs index 0603d278b71fd..db9cf7bf9f6d5 100644 --- a/mcs/class/corlib/Test/System.Threading/ThreadTest.cs +++ b/mcs/class/corlib/Test/System.Threading/ThreadTest.cs @@ -477,7 +477,6 @@ public void TestIsBackground1 () } [Test] - [Category ("NotDotNet")] // on MS, ThreadState is immediately Stopped after Abort public void TestIsBackground2 () { C2Test test1 = new C2Test(); @@ -488,7 +487,9 @@ public void TestIsBackground2 () } finally { TestThread.Abort(); } - Assert.IsTrue (TestThread.IsBackground, "#52 Is Background Changed to Start "); + + if (TestThread.IsAlive) + Assert.IsTrue (TestThread.IsBackground, "#52 Is Background Changed to Start "); } [Test]