| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS d.file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS d.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 d.file. | 3 // BSD-style license that can be found in the LICENSE d.file. |
| 4 | 4 |
| 5 import 'package:path/path.dart' as path; | 5 import 'package:path/path.dart' as path; |
| 6 | 6 |
| 7 import '../../../lib/src/exit_codes.dart' as exit_codes; | 7 import '../../../lib/src/exit_codes.dart' as exit_codes; |
| 8 import '../../descriptor.dart' as d; | 8 import '../../descriptor.dart' as d; |
| 9 import '../../test_pub.dart'; | 9 import '../../test_pub.dart'; |
| 10 | 10 |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 d.dir("foo", [ | 31 d.dir("foo", [ |
| 32 d.file("foo.dart", 'main() => "foo";') | 32 d.file("foo.dart", 'main() => "foo";') |
| 33 ]) | 33 ]) |
| 34 ]).validate(); | 34 ]).validate(); |
| 35 }); | 35 }); |
| 36 | 36 |
| 37 integration("path is relative to containing d.pubspec", () { | 37 integration("path is relative to containing d.pubspec", () { |
| 38 d.dir("relative", [ | 38 d.dir("relative", [ |
| 39 d.dir("foo", [ | 39 d.dir("foo", [ |
| 40 d.libDir("foo"), | 40 d.libDir("foo"), |
| 41 d.libPubspec("foo", "0.0.1", deps: [ | 41 d.libPubspec("foo", "0.0.1", deps: { |
| 42 {"path": "../bar"} | 42 "bar": {"path": "../bar"} |
| 43 ]) | 43 }) |
| 44 ]), | 44 ]), |
| 45 d.dir("bar", [ | 45 d.dir("bar", [ |
| 46 d.libDir("bar"), | 46 d.libDir("bar"), |
| 47 d.libPubspec("bar", "0.0.1") | 47 d.libPubspec("bar", "0.0.1") |
| 48 ]) | 48 ]) |
| 49 ]).create(); | 49 ]).create(); |
| 50 | 50 |
| 51 d.dir(appPath, [ | 51 d.dir(appPath, [ |
| 52 d.pubspec({ | 52 d.pubspec({ |
| 53 "name": "myapp", | 53 "name": "myapp", |
| 54 "dependencies": { | 54 "dependencies": { |
| 55 "foo": {"path": "../relative/foo"} | 55 "foo": {"path": "../relative/foo"} |
| 56 } | 56 } |
| 57 }) | 57 }) |
| 58 ]).create(); | 58 ]).create(); |
| 59 | 59 |
| 60 pubInstall(); | 60 pubInstall(); |
| 61 | 61 |
| 62 d.dir(packagesPath, [ | 62 d.dir(packagesPath, [ |
| 63 d.dir("foo", [ | 63 d.dir("foo", [ |
| 64 d.file("foo.dart", 'main() => "foo";') | 64 d.file("foo.dart", 'main() => "foo";') |
| 65 ]), | 65 ]), |
| 66 d.dir("bar", [ | 66 d.dir("bar", [ |
| 67 d.file("bar.dart", 'main() => "bar";') | 67 d.file("bar.dart", 'main() => "bar";') |
| 68 ]) | 68 ]) |
| 69 ]).validate(); | 69 ]).validate(); |
| 70 }); | 70 }); |
| 71 } | 71 } |
| OLD | NEW |