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 import 'dart:io'; | |
6 | |
7 import 'package:path/path.dart' as p; | 5 import 'package:path/path.dart' as p; |
8 import 'package:scheduled_test/scheduled_process.dart'; | 6 import 'package:scheduled_test/scheduled_process.dart'; |
9 import 'package:scheduled_test/scheduled_test.dart'; | |
10 | 7 |
11 import '../../descriptor.dart' as d; | 8 import '../../descriptor.dart' as d; |
12 import '../../test_pub.dart'; | 9 import '../../test_pub.dart'; |
13 import 'utils.dart'; | 10 import 'utils.dart'; |
14 | 11 |
15 main() { | 12 main() { |
16 integration("the generated binstub runs a snapshotted executable", () { | 13 integration("the generated binstub runs a snapshotted executable", () { |
17 servePackages((builder) { | 14 servePackages((builder) { |
18 builder.serve("foo", "1.0.0", pubspec: { | 15 builder.serve("foo", "1.0.0", pubspec: { |
19 "executables": { | 16 "executables": { |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 | 51 |
55 var process = new ScheduledProcess.start( | 52 var process = new ScheduledProcess.start( |
56 p.join(sandboxDir, cachePath, "bin", binStubName("foo-script")), | 53 p.join(sandboxDir, cachePath, "bin", binStubName("foo-script")), |
57 ["arg1", "arg2"], | 54 ["arg1", "arg2"], |
58 environment: getEnvironment()); | 55 environment: getEnvironment()); |
59 | 56 |
60 process.stdout.expect("ok [arg1, arg2]"); | 57 process.stdout.expect("ok [arg1, arg2]"); |
61 process.shouldExit(); | 58 process.shouldExit(); |
62 }); | 59 }); |
63 } | 60 } |
OLD | NEW |