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

Side by Side Diff: tools/testing/dart/test_suite.dart

Issue 540933002: test.dart: Serve the browser test driver page from the test file HTTP server. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 3 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 /** 5 /**
6 * Classes and methods for enumerating and preparing tests. 6 * Classes and methods for enumerating and preparing tests.
7 * 7 *
8 * This library includes: 8 * This library includes:
9 * 9 *
10 * - Creating tests by listing all the Dart files in certain directories, 10 * - Creating tests by listing all the Dart files in certain directories,
(...skipping 1267 matching lines...) Expand 10 before | Expand all | Expand 10 after
1278 dartFlags.add("--enable_type_checks"); 1278 dartFlags.add("--enable_type_checks");
1279 } 1279 }
1280 dartFlags.addAll(vmOptions); 1280 dartFlags.addAll(vmOptions);
1281 } 1281 }
1282 1282
1283 commandSet.add(CommandBuilder.instance.getContentShellCommand( 1283 commandSet.add(CommandBuilder.instance.getContentShellCommand(
1284 contentShellFilename, fullHtmlPath, contentShellOptions, 1284 contentShellFilename, fullHtmlPath, contentShellOptions,
1285 dartFlags, environmentOverrides)); 1285 dartFlags, environmentOverrides));
1286 } else { 1286 } else {
1287 commandSet.add(CommandBuilder.instance.getBrowserTestCommand( 1287 commandSet.add(CommandBuilder.instance.getBrowserTestCommand(
1288 runtime, fullHtmlPath, checkedMode: configuration['checked'])); 1288 runtime, fullHtmlPath, configuration));
1289 } 1289 }
1290 1290
1291 // Create BrowserTestCase and queue it. 1291 // Create BrowserTestCase and queue it.
1292 String testDisplayName = '$suiteName/$testName'; 1292 String testDisplayName = '$suiteName/$testName';
1293 var testCase; 1293 var testCase;
1294 if (info.optionsFromFile['isMultiHtmlTest']) { 1294 if (info.optionsFromFile['isMultiHtmlTest']) {
1295 testDisplayName = '$testDisplayName/${subtestNames[subtestIndex]}'; 1295 testDisplayName = '$testDisplayName/${subtestNames[subtestIndex]}';
1296 testCase = new BrowserTestCase(testDisplayName, 1296 testCase = new BrowserTestCase(testDisplayName,
1297 commandSet, configuration, 1297 commandSet, configuration,
1298 expectations['$testName/${subtestNames[subtestIndex]}'], 1298 expectations['$testName/${subtestNames[subtestIndex]}'],
(...skipping 656 matching lines...) Expand 10 before | Expand all | Expand 10 after
1955 // See issue 16264. 1955 // See issue 16264.
1956 if (Platform.operatingSystem == 'windows') { 1956 if (Platform.operatingSystem == 'windows') {
1957 var native_path = new Path(path).toNativePath(); 1957 var native_path = new Path(path).toNativePath();
1958 // Running this in a shell sucks, but rmdir is not part of the standard 1958 // Running this in a shell sucks, but rmdir is not part of the standard
1959 // path. 1959 // path.
1960 return Process.run('rmdir', ['/s', '/q', native_path], runInShell: true) 1960 return Process.run('rmdir', ['/s', '/q', native_path], runInShell: true)
1961 .then((ProcessResult result) { 1961 .then((ProcessResult result) {
1962 if (result.exitCode != 0) { 1962 if (result.exitCode != 0) {
1963 throw new Exception('Can\'t delete path $native_path. ' 1963 throw new Exception('Can\'t delete path $native_path. '
1964 'This path might be too long'); 1964 'This path might be too long');
1965 } 1965 }
1966 }); 1966 });
1967 } else { 1967 } else {
1968 var dir = new Directory(path); 1968 var dir = new Directory(path);
1969 return dir.delete(recursive: true); 1969 return dir.delete(recursive: true);
1970 } 1970 }
1971 } 1971 }
1972 1972
1973 static Path debugLogfile() { 1973 static Path debugLogfile() {
1974 return new Path(".debug.log"); 1974 return new Path(".debug.log");
1975 } 1975 }
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after
2286 * $pass tests are expected to pass 2286 * $pass tests are expected to pass
2287 * $failOk tests are expected to fail that we won't fix 2287 * $failOk tests are expected to fail that we won't fix
2288 * $fail tests are expected to fail that we should fix 2288 * $fail tests are expected to fail that we should fix
2289 * $crash tests are expected to crash that we should fix 2289 * $crash tests are expected to crash that we should fix
2290 * $timeout tests are allowed to timeout 2290 * $timeout tests are allowed to timeout
2291 * $compileErrorSkip tests are skipped on browsers due to compile-time error 2291 * $compileErrorSkip tests are skipped on browsers due to compile-time error
2292 """; 2292 """;
2293 print(report); 2293 print(report);
2294 } 2294 }
2295 } 2295 }
OLDNEW
« tools/testing/dart/browser_controller.dart ('K') | « tools/testing/dart/test_runner.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698