| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | |
| 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. | |
| 4 | |
| 5 import 'package:scheduled_test/scheduled_test.dart'; | |
| 6 | |
| 7 import '../descriptor.dart' as d; | |
| 8 import '../test_pub.dart'; | |
| 9 | |
| 10 main() { | |
| 11 initConfig(); | |
| 12 | |
| 13 integration("includes .dart files from dependencies in debug mode", () { | |
| 14 // Dart2js can take a long time to compile dart code, so we increase the | |
| 15 // timeout to cope with that. | |
| 16 currentSchedule.timeout *= 3; | |
| 17 | |
| 18 d.dir("foo", [ | |
| 19 d.libPubspec("foo", "0.0.1"), | |
| 20 d.dir("lib", [ | |
| 21 d.file('foo.dart', 'foo() => print("hello");'), | |
| 22 d.dir("sub", [ | |
| 23 d.file('bar.dart', 'bar() => print("hello");'), | |
| 24 ]) | |
| 25 ]) | |
| 26 ]).create(); | |
| 27 | |
| 28 d.dir(appPath, [ | |
| 29 d.appPubspec({ | |
| 30 "foo": {"path": "../foo"} | |
| 31 }), | |
| 32 d.dir("example", [ | |
| 33 d.file("main.dart", 'myapp() => print("not entrypoint");'), | |
| 34 d.dir("sub", [ | |
| 35 d.file("main.dart", 'myapp() => print("not entrypoint");') | |
| 36 ]) | |
| 37 ]) | |
| 38 ]).create(); | |
| 39 | |
| 40 schedulePub(args: ["build", "--mode", "debug", "example"], | |
| 41 output: new RegExp(r'Built \d+ files to "build".')); | |
| 42 | |
| 43 d.dir(appPath, [ | |
| 44 d.dir('build', [ | |
| 45 d.dir('example', [ | |
| 46 d.file("main.dart", 'myapp() => print("not entrypoint");'), | |
| 47 d.dir('packages', [ | |
| 48 d.dir('foo', [ | |
| 49 d.file('foo.dart', 'foo() => print("hello");'), | |
| 50 d.dir("sub", [ | |
| 51 d.file('bar.dart', 'bar() => print("hello");'), | |
| 52 ]) | |
| 53 ]) | |
| 54 ]), | |
| 55 d.dir("sub", [ | |
| 56 d.file("main.dart", 'myapp() => print("not entrypoint");'), | |
| 57 // Does *not* copy packages into subdirectories. | |
| 58 d.nothing("packages") | |
| 59 ]) | |
| 60 ]) | |
| 61 ]) | |
| 62 ]).validate(); | |
| 63 }); | |
| 64 } | |
| OLD | NEW |