| OLD | NEW |
| 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 executing tests. | 6 * Classes and methods for executing tests. |
| 7 * | 7 * |
| 8 * This module includes: | 8 * This module includes: |
| 9 * - Managing parallel execution of tests, including timeout checks. | 9 * - Managing parallel execution of tests, including timeout checks. |
| 10 * - Evaluating the output of each test as pass/fail/crash/timeout. | 10 * - Evaluating the output of each test as pass/fail/crash/timeout. |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 109 String commandLine; | 109 String commandLine; |
| 110 | 110 |
| 111 Command(this.executable, this.arguments, [this.environment = null]) { | 111 Command(this.executable, this.arguments, [this.environment = null]) { |
| 112 if (io.Platform.operatingSystem == 'windows') { | 112 if (io.Platform.operatingSystem == 'windows') { |
| 113 // Windows can't handle the first command if it is a .bat file or the like | 113 // Windows can't handle the first command if it is a .bat file or the like |
| 114 // with the slashes going the other direction. | 114 // with the slashes going the other direction. |
| 115 // TODO(efortuna): Remove this when fixed (Issue 1306). | 115 // TODO(efortuna): Remove this when fixed (Issue 1306). |
| 116 executable = executable.replaceAll('/', '\\'); | 116 executable = executable.replaceAll('/', '\\'); |
| 117 } | 117 } |
| 118 var quotedArguments = []; | 118 var quotedArguments = []; |
| 119 arguments.forEach((argument) => quotedArguments.add('"$argument"')); | 119 quotedArguments.add(escapeCommandLineArgument(executable)); |
| 120 commandLine = "\"$executable\" ${quotedArguments.join(' ')}"; | 120 quotedArguments.addAll(arguments.map(escapeCommandLineArgument)); |
| 121 commandLine = quotedArguments.join(' '); |
| 121 } | 122 } |
| 122 | 123 |
| 123 String toString() => commandLine; | 124 String toString() => commandLine; |
| 124 | 125 |
| 125 Future<bool> get outputIsUpToDate => new Future.immediate(false); | 126 Future<bool> get outputIsUpToDate => new Future.immediate(false); |
| 126 io.Path get expectedOutputFile => null; | 127 io.Path get expectedOutputFile => null; |
| 127 bool get isPixelTest => false; | 128 bool get isPixelTest => false; |
| 128 } | 129 } |
| 129 | 130 |
| 130 class CompilationCommand extends Command { | 131 class CompilationCommand extends Command { |
| (...skipping 1779 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1910 } | 1911 } |
| 1911 } | 1912 } |
| 1912 | 1913 |
| 1913 void eventAllTestsDone() { | 1914 void eventAllTestsDone() { |
| 1914 for (var listener in _eventListener) { | 1915 for (var listener in _eventListener) { |
| 1915 listener.allDone(); | 1916 listener.allDone(); |
| 1916 } | 1917 } |
| 1917 } | 1918 } |
| 1918 } | 1919 } |
| 1919 | 1920 |
| OLD | NEW |