| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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 library runtime_configuration; | 5 library runtime_configuration; |
| 6 | 6 |
| 7 import 'dart:io' show Directory, File; | 7 import 'dart:io' show Directory, File; |
| 8 | 8 |
| 9 import 'compiler_configuration.dart' show CommandArtifact; | 9 import 'compiler_configuration.dart' show CommandArtifact; |
| 10 | 10 |
| (...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 221 | 221 |
| 222 /// The standalone Dart VM binary, "dart" or "dart.exe". | 222 /// The standalone Dart VM binary, "dart" or "dart.exe". |
| 223 class StandaloneDartRuntimeConfiguration extends DartVmRuntimeConfiguration { | 223 class StandaloneDartRuntimeConfiguration extends DartVmRuntimeConfiguration { |
| 224 List<Command> computeRuntimeCommands( | 224 List<Command> computeRuntimeCommands( |
| 225 TestSuite suite, | 225 TestSuite suite, |
| 226 CommandBuilder commandBuilder, | 226 CommandBuilder commandBuilder, |
| 227 CommandArtifact artifact, | 227 CommandArtifact artifact, |
| 228 List<String> arguments, | 228 List<String> arguments, |
| 229 Map<String, String> environmentOverrides) { | 229 Map<String, String> environmentOverrides) { |
| 230 final bool needsDFERunner = suite.configuration['compiler'] == 'dartk' && | 230 final bool needsDFERunner = suite.configuration['compiler'] == 'dartk' && |
| 231 !suite.configuration['use-standalone-dartk']; | 231 !suite.configuration['noBatch']; |
| 232 String script = artifact.filename; | 232 String script = artifact.filename; |
| 233 String type = artifact.mimeType; | 233 String type = artifact.mimeType; |
| 234 if (script != null && | 234 if (script != null && |
| 235 type != 'application/dart' && | 235 type != 'application/dart' && |
| 236 type != 'application/dart-snapshot') { | 236 type != 'application/dart-snapshot') { |
| 237 throw "Dart VM cannot run files of type '$type'."; | 237 throw "Dart VM cannot run files of type '$type'."; |
| 238 } | 238 } |
| 239 String executable = suite.dartVmBinaryFileName; | 239 String executable = suite.dartVmBinaryFileName; |
| 240 return <Command>[ | 240 return <Command>[ |
| 241 commandBuilder.getVmCommand(executable, arguments, environmentOverrides, n
eedsDFERunner: needsDFERunner) | 241 commandBuilder.getVmCommand(executable, arguments, environmentOverrides, n
eedsDFERunner: needsDFERunner) |
| (...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 363 class DummyRuntimeConfiguration extends DartVmRuntimeConfiguration { | 363 class DummyRuntimeConfiguration extends DartVmRuntimeConfiguration { |
| 364 List<Command> computeRuntimeCommands( | 364 List<Command> computeRuntimeCommands( |
| 365 TestSuite suite, | 365 TestSuite suite, |
| 366 CommandBuilder commandBuilder, | 366 CommandBuilder commandBuilder, |
| 367 CommandArtifact artifact, | 367 CommandArtifact artifact, |
| 368 List<String> arguments, | 368 List<String> arguments, |
| 369 Map<String, String> environmentOverrides) { | 369 Map<String, String> environmentOverrides) { |
| 370 throw "Unimplemented runtime '$runtimeType'"; | 370 throw "Unimplemented runtime '$runtimeType'"; |
| 371 } | 371 } |
| 372 } | 372 } |
| OLD | NEW |