[mono/monodevelop] [2 commits] 6abc8da9: [Test Results] Fix lots of assertion fails where fraction is not in [0, 1].
| Newsgroups | gmane.comp.gnome.mono.patches |
|---|---|
| Message-ID | <00000141eedcc808-8ff5154e-f250-4045-90e5-a979b5c5781e-000000@email.amazonses.com> |
Branch: refs/heads/master
Home: https://github.com/mono/monodevelop
Compare: https://github.com/mono/monodevelop/compare/e7a70cf7dd64...6c89bb46d4cb
Commit: 6abc8da9d2153952b6b162dcf8256f2865fee239
Author: Therzok <[email protected]> (Therzok)
Date: 2013-10-24 09:59:29 GMT
URL: https://github.com/mono/monodevelop/commit/6abc8da9d2153952b6b162dcf8256f2865fee239
[Test Results] Fix lots of assertion fails where fraction is not in [0, 1].
Maybe there is a better fix?
Changed paths:
M main/src/addins/NUnit/Gui/TestResultsPad.cs
Modified: main/src/addins/NUnit/Gui/TestResultsPad.cs
===================================================================
@@ -667,6 +667,12 @@ void ITestProgressMonitor.EndTest (UnitTest test, UnitTestResult result)
frac = ((double)testsRun / (double)testsToRun);
else
frac = 1;
+
+ if (frac < 0)
+ frac = 0;
+ else if (frac > 1)
+ frac = 1;
+
progressBar.Fraction = frac;
progressBar.Text = testsRun + " / " + testsToRun;
}
Commit: 6c89bb46d4cbfc3aa0d240ea0fb88bec04f3e28d
Author: Lluis Sanchez <[email protected]> (slluis)
Date: 2013-10-25 09:03:44 GMT
URL: https://github.com/mono/monodevelop/commit/6c89bb46d4cbfc3aa0d240ea0fb88bec04f3e28d
Merge pull request #421 from mono/testResultsPad
[Test Results] Fix lots of assertion fails where fraction is not in [0,1]
Changed paths:
M main/src/addins/NUnit/Gui/TestResultsPad.cs
Modified: main/src/addins/NUnit/Gui/TestResultsPad.cs
===================================================================
@@ -667,6 +667,12 @@ void ITestProgressMonitor.EndTest (UnitTest test, UnitTestResult result)
frac = ((double)testsRun / (double)testsToRun);
else
frac = 1;
+
+ if (frac < 0)
+ frac = 0;
+ else if (frac > 1)
+ frac = 1;
+
progressBar.Fraction = frac;
progressBar.Text = testsRun + " / " + testsToRun;
}
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches