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

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

Issue 9117010: Fix frogsh + Windows + test.dart take 2 (Closed) Base URL: http://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 | « tools/testing/dart/test_runner.dart ('k') | tools/testing/perf_testing/perf_README.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/testing/dart/test_suite.dart
===================================================================
--- tools/testing/dart/test_suite.dart (revision 3517)
+++ tools/testing/dart/test_suite.dart (working copy)
@@ -409,7 +409,15 @@
// the client/samples/dartcombat test to its css file, remove the
// "../../" from this path, and move this out of the isWebTest guard.
// Also remove getHtmlName, and just use test.html.
- htmlPath = '${tempDir.path}/../../${getHtmlName(filename)}';
+ // TODO(efortuna): this shortening of htmlFilename is a band-aid until
+ // the above TODO gets fixed. Windows cannot have paths that are longer
+ // than 260 characters, and without this hack, we were running past the
+ // the limit.
+ String htmlFilename = getHtmlName(filename);
+ while ('${tempDir.path}/../../$htmlFilename'.length >= 260) {
+ htmlFilename = htmlFilename.substring(htmlFilename.length~/2);
+ }
+ htmlPath = '${tempDir.path}/../../$htmlFilename';
}
final String scriptPath = (component == 'dartium') ?
dartWrapperFilename : compiledDartWrapperFilename;
@@ -461,9 +469,14 @@
String executable = getFilename(dumpRenderTreeFilename);
List<String> args;
if (component == 'webdriver') {
- // TODO(efortuna): These paths are not OS independent!
executable = '$dartDir/tools/testing/run_selenium.py';
- args = ['--out', htmlPath, '--browser', configuration['browser']];
+ if (new Platform().operatingSystem() == 'windows') {
+ // For Windows, the first command, must have the Windows
+ // slash direction.
+ // TODO(efortuna): Get rid of this hack when issue 1306 is fixed.
+ executable = executable.replaceAll('/', '\\');
+ }
+ args = ['--out=$htmlPath', '--browser=${configuration["browser"]}'];
} else {
args = ['--no-timeout'];
if (component == 'dartium') {
@@ -899,22 +912,21 @@
case 'leg':
return 'frog/bin/frog$postfix';
case 'frogsh':
- return 'frog/bin/frogsh$postfix';
+ return 'frog/bin/frogsh';
default:
throw "Unknown executable for: ${configuration['component']}";
}
}
static String compilerName(Map configuration) {
- String postfix =
- (new Platform().operatingSystem() == 'windows') ? '.exe' : '';
+ String postfix = executableSuffix;
switch (configuration['component']) {
case 'chromium':
case 'dartc':
return 'compiler/bin/dartc$postfix';
case 'frogium':
case 'webdriver':
- return 'frog/bin/frogsh$postfix';
+ return 'frog/bin/frogsh';
default:
throw "Unknown compiler for: ${configuration['component']}";
}
« no previous file with comments | « tools/testing/dart/test_runner.dart ('k') | tools/testing/perf_testing/perf_README.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698