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

Unified Diff: tests/co19/test_config.dart

Issue 9315052: Allow test.dart to handle the co19 test suite if it is not checked out. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/co19/test_config.dart
diff --git a/tests/co19/test_config.dart b/tests/co19/test_config.dart
index f1e109f86fba175c3f5a958dc3e280f4fcafa2c0..c4f07ab7182a3fd9a7db5f75a3b003672f0228a0 100644
--- a/tests/co19/test_config.dart
+++ b/tests/co19/test_config.dart
@@ -4,6 +4,7 @@
#library("co19_test_config");
+#import("dart:io");
#import("../../tools/testing/dart/test_suite.dart");
class Co19TestSuite extends StandardTestSuite {
@@ -17,6 +18,18 @@ class Co19TestSuite extends StandardTestSuite {
"tests/co19/co19-runtime.status",
"tests/co19/co19-frog.status"]);
+ // A Dart checkout may omit the check out of the co19 tests.
+ void forEachTest(Function onTest, Map testCache, String globalTempDir(),
+ [Function onDone = null]) {
+ Directory testDirectory =
+ new Directory(TestUtils.dartDir() + '/tests/co19/src');
+ if (testDirectory.existsSync()) {
+ super.forEachTest(onTest, testCache, globalTempDir, onDone);
+ } else {
+ if (onDone != null) onDone();
+ }
+ }
+
bool isTestFile(String filename) => _testRegExp.hasMatch(filename);
bool listRecursively() => true;
bool complexStatusMatching() => true;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698