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

Side by Side Diff: tests/standalone/io/test_runner_test.dart

Issue 22859009: Changes to how we handle fancy stacks: (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 4 months 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 import "dart:io"; 5 import "dart:io";
6 import "dart:isolate"; 6 import "dart:isolate";
7 import "dart:async"; 7 import "dart:async";
8 import "dart:utf"; 8 import "dart:utf";
9 import "../../../tools/testing/dart/test_runner.dart"; 9 import "../../../tools/testing/dart/test_runner.dart";
10 import "../../../tools/testing/dart/test_suite.dart"; 10 import "../../../tools/testing/dart/test_suite.dart";
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 void done(TestCase test) { 111 void done(TestCase test) {
112 TestController.processCompletedTest(test); 112 TestController.processCompletedTest(test);
113 } 113 }
114 } 114 }
115 115
116 void main() { 116 void main() {
117 // Run the test_runner_test if there are no command-line options. 117 // Run the test_runner_test if there are no command-line options.
118 // Otherwise, run one of the component tests that always pass, 118 // Otherwise, run one of the component tests that always pass,
119 // fail, or timeout. 119 // fail, or timeout.
120 var arguments = new Options().arguments; 120 var arguments = new Options().arguments;
121 arguments.remove('--no-fancy-stacks'); // The test runner can add this.
122 arguments.remove('--no-filtered-stacks'); // The test runner can add this.
121 if (arguments.isEmpty) { 123 if (arguments.isEmpty) {
122 testProcessQueue(); 124 testProcessQueue();
123 } else { 125 } else {
124 switch (arguments[0]) { 126 switch (arguments[0]) {
125 case 'pass': 127 case 'pass':
126 return; 128 return;
127 case 'fail-unexpected': 129 case 'fail-unexpected':
128 case 'fail': 130 case 'fail':
129 throw "This test always fails, to test the test scripts."; 131 throw "This test always fails, to test the test scripts.";
130 break; 132 break;
131 case 'timeout': 133 case 'timeout':
132 // Run for 10 seconds, then exit. This tests a 2 second timeout. 134 // Run for 10 seconds, then exit. This tests a 2 second timeout.
133 new Timer(new Duration(seconds: 10), (){ }); 135 new Timer(new Duration(seconds: 10), (){ });
134 break; 136 break;
135 default: 137 default:
136 throw "Unknown option ${arguments[0]} passed to test_runner_test"; 138 throw "Unknown option ${arguments[0]} passed to test_runner_test";
137 } 139 }
138 } 140 }
139 } 141 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698