OLD | NEW |
(Empty) | |
| 1 import 'package:path/path.dart' as path; |
| 2 import '../descriptor.dart' as d; |
| 3 import '../test_pub.dart'; |
| 4 const SCRIPT = r""" |
| 5 import '../../a.dart'; |
| 6 import '../b.dart'; |
| 7 main() { |
| 8 print("$a $b"); |
| 9 } |
| 10 """; |
| 11 main() { |
| 12 initConfig(); |
| 13 integration( |
| 14 'allows assets in parent directories of the entrypoint to be' 'accessed', |
| 15 () { |
| 16 d.dir( |
| 17 appPath, |
| 18 [ |
| 19 d.appPubspec(), |
| 20 d.dir( |
| 21 "tool", |
| 22 [ |
| 23 d.file("a.dart", "var a = 'a';"), |
| 24 d.dir( |
| 25 "a", |
| 26 [ |
| 27 d.file("b.dart", "var b = 'b';"), |
| 28 d.dir("b", [d.file("app.dart", SCRIPT)])])])]).creat
e(); |
| 29 var pub = pubRun(args: [path.join("tool", "a", "b", "app")]); |
| 30 pub.stdout.expect("a b"); |
| 31 pub.shouldExit(); |
| 32 }); |
| 33 } |
OLD | NEW |