| 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( | |
| 19 "foo", | |
| 20 [ | |
| 21 d.libPubspec("foo", "0.0.1"), | |
| 22 d.dir( | |
| 23 "lib", | |
| 24 [ | |
| 25 d.file('foo.dart', 'foo() => print("hello");'), | |
| 26 d.dir("sub", [d.file('bar.dart', 'bar() => print("hello");')
,])])]).create(); | |
| 27 | |
| 28 d.dir(appPath, [d.appPubspec({ | |
| 29 "foo": { | |
| 30 "path": "../foo" | |
| 31 } | |
| 32 }), | |
| 33 d.dir( | |
| 34 "example", | |
| 35 [ | |
| 36 d.file("main.dart", 'myapp() => print("not entrypoint");'), | |
| 37 d.dir( | |
| 38 "sub", | |
| 39 [d.file("main.dart", 'myapp() => print("not entrypoint");'
)])])]).create(); | |
| 40 | |
| 41 schedulePub( | |
| 42 args: ["build", "--mode", "debug", "example"], | |
| 43 output: new RegExp(r'Built \d+ files to "build".')); | |
| 44 | |
| 45 d.dir( | |
| 46 appPath, | |
| 47 [ | |
| 48 d.dir( | |
| 49 'build', | |
| 50 [ | |
| 51 d.dir( | |
| 52 'example', | |
| 53 [ | |
| 54 d.file("main.dart", 'myapp() => print("not entrypoin
t");'), | |
| 55 d.dir( | |
| 56 'packages', | |
| 57 [ | |
| 58 d.dir( | |
| 59 'foo', | |
| 60 [ | |
| 61 d.file('foo.dart', 'foo() => print("
hello");'), | |
| 62 d.dir("sub", [d.file('bar.dart', 'ba
r() => print("hello");'),])])]), | |
| 63 d.dir( | |
| 64 "sub", | |
| 65 [ | |
| 66 d.file("main.dart", 'myapp() => print("not e
ntrypoint");'), | |
| 67 // Does *not* copy packages into subdirector
ies. | |
| 68 d.nothing("packages")])])])]).validate(); | |
| 69 }); | |
| 70 } | |
| OLD | NEW |