Chromium Code Reviews| Index: tools/testing/dart/test_suite.dart |
| diff --git a/tools/testing/dart/test_suite.dart b/tools/testing/dart/test_suite.dart |
| index 6381a12bb2d8e253e0b8085b3d622f889204636b..a6af92fb3931176091587c6be414d0ee0652e5d1 100644 |
| --- a/tools/testing/dart/test_suite.dart |
| +++ b/tools/testing/dart/test_suite.dart |
| @@ -966,18 +966,29 @@ class StandardTestSuite extends TestSuite { |
| commands.add(_compileCommand( |
| dartWrapperFilename, compiledDartWrapperFilename, |
| compiler, tempDir, vmOptions, optionsFromFile)); |
| + } |
| - // some tests require compiling multiple input scripts. |
| - List<String> otherScripts = optionsFromFile['otherScripts']; |
| - for (String name in otherScripts) { |
| - Path namePath = new Path(name); |
| + // some tests require compiling multiple input scripts. |
| + List<String> otherScripts = optionsFromFile['otherScripts']; |
| + for (String name in otherScripts) { |
| + Path namePath = new Path(name); |
| + String baseName = namePath.filenameWithoutExtension; |
| + Path fromPath = filePath.directoryPath.join(namePath); |
| + if (compiler != 'none') { |
| assert(namePath.extension == 'dart'); |
| - String baseName = namePath.filenameWithoutExtension; |
| - Path fromPath = filePath.directoryPath.join(namePath); |
| commands.add(_compileCommand( |
| - fromPath.toNativePath(), '$tempDir/$baseName.js', |
| + fromPath.toNativePath(), '$tempDir/../$baseName.js', |
|
kustermann
2013/04/11 20:32:44
We can't do that (i.e. '..'). If multiple tests ha
|
| compiler, tempDir, vmOptions, optionsFromFile)); |
| } |
| + // Because of our test server's configuration, browser tests expect |
| + // these helper files to be at the top level of the generated_tests |
| + // directory (we could modify the tests, but then the same test couldn't |
| + // be run both on the command line and in the browser). |
| + if (compiler == 'none') { |
| + File fromFile = new File.fromPath(fromPath); |
| + File toFile = new File('$tempDir/../$baseName.dart'); |
| + fromFile.openRead().pipe(toFile.openWrite()); |
|
kustermann
2013/04/11 20:32:44
This is an asynchronous operation. It could happen
|
| + } |
| } |
| // Variables for browser multi-tests. |