Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(55)

Unified Diff: tools/testing/dart/test_runner.dart

Issue 8636012: Make Dart test scripts work for the VM on Windows. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/testing/dart/test_options.dart ('k') | tools/testing/dart/test_suite.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/testing/dart/test_runner.dart
diff --git a/tools/testing/dart/test_runner.dart b/tools/testing/dart/test_runner.dart
index c1650d182e7a233407cfeef5dcdf8abfd56ced06..7a7567e6f512fce1de7e38ce29b965e23c4d4bf0 100644
--- a/tools/testing/dart/test_runner.dart
+++ b/tools/testing/dart/test_runner.dart
@@ -71,8 +71,22 @@ class TestOutput {
// The Java dartc runner exits with code 253 in case of unhandles
// exceptions.
- bool get hasCrashed() =>
- !timedOut && (exitCode != -1) && ((exitCode < 0) || (exitCode == 253));
+ // The VM uses std::abort to terminate on asserts.
+ // std::abort terminates with exit code 3 on Windows.
+ bool get hasCrashed() {
+ if (new Platform().operatingSystem() == 'windows') {
+ if (exitCode == 3) {
+ return !timedOut;
+ }
+ return (!timedOut &&
+ (exitCode != -1) &&
+ (exitCode < 0) &&
+ ((0x3FFFFF00 & exitCode) == 0));
+ }
+ return (!timedOut &&
+ (exitCode != -1) &&
+ ((exitCode < 0) || (exitCode == 253)));
+ }
bool get hasTimedOut() => timedOut;
« no previous file with comments | « tools/testing/dart/test_options.dart ('k') | tools/testing/dart/test_suite.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698