Chromium Code Reviews| Index: tools/testing/dart/runtime_configuration.dart |
| diff --git a/tools/testing/dart/runtime_configuration.dart b/tools/testing/dart/runtime_configuration.dart |
| index 71913427ccdc30dd2f90a7c9dc897087a4aae1b5..213a07c44757ffa59cc20e98c0fdf7de4ae644ee 100644 |
| --- a/tools/testing/dart/runtime_configuration.dart |
| +++ b/tools/testing/dart/runtime_configuration.dart |
| @@ -54,6 +54,9 @@ class RuntimeConfiguration { |
| return new DartProductRuntimeConfiguration(); |
| case 'dart_precompiled': |
| + if (configuration['system'] == 'android') { |
| + return new DartPrecompiledAdbRuntimeConfiguration(useBlobs: useBlobs); |
| + } |
| return new DartPrecompiledRuntimeConfiguration(useBlobs: useBlobs); |
| case 'drt': |
| @@ -275,6 +278,32 @@ class DartPrecompiledRuntimeConfiguration extends DartVmRuntimeConfiguration { |
| } |
| } |
| +class DartPrecompiledAdbRuntimeConfiguration |
| + extends DartVmRuntimeConfiguration { |
| + final bool useBlobs; |
| + DartPrecompiledAdbRuntimeConfiguration({bool useBlobs}) : useBlobs = useBlobs; |
| + |
| + List<Command> computeRuntimeCommands( |
| + TestSuite suite, |
| + CommandBuilder commandBuilder, |
| + CommandArtifact artifact, |
| + List<String> arguments, |
| + Map<String, String> environmentOverrides) { |
| + String script = artifact.filename; |
| + String type = artifact.mimeType; |
| + if (script != null && type != 'application/dart-precompiled') { |
| + throw "dart_precompiled cannot run files of type '$type'."; |
| + } |
| + |
| + String precompiledRunner = suite.dartPrecompiledBinaryFileName; |
| + return <Command>[ |
| + commandBuilder.getAdbPrecompiledCommand(precompiledRunner, |
| + artifact.filename, |
|
Bill Hesse
2016/04/27 12:22:32
script is a local == artifact.filename.
kustermann
2016/04/27 13:25:09
Done.
Strictly speaking it's not even a filename
|
| + useBlobs) |
| + ]; |
| + } |
| +} |
| + |
| /// Temporary runtime configuration for browser runtimes that haven't been |
| /// migrated yet. |
| // TODO(ahe): Remove this class. |