OLD | NEW |
(Empty) | |
| 1 library pub_tests; |
| 2 import '../../descriptor.dart' as d; |
| 3 import '../../test_pub.dart'; |
| 4 main() { |
| 5 initConfig(); |
| 6 integration('"--all" adds all non-installed versions of the package', () { |
| 7 servePackages((builder) { |
| 8 builder.serve("foo", "1.2.1"); |
| 9 builder.serve("foo", "1.2.2"); |
| 10 builder.serve("foo", "1.2.3"); |
| 11 builder.serve("foo", "2.0.0"); |
| 12 }); |
| 13 schedulePub( |
| 14 args: ["cache", "add", "foo", "-v", "1.2.1"], |
| 15 output: 'Downloading foo 1.2.1...'); |
| 16 schedulePub( |
| 17 args: ["cache", "add", "foo", "-v", "1.2.3"], |
| 18 output: 'Downloading foo 1.2.3...'); |
| 19 schedulePub(args: ["cache", "add", "foo", "--all"], output: ''' |
| 20 Already cached foo 1.2.1. |
| 21 Downloading foo 1.2.2... |
| 22 Already cached foo 1.2.3. |
| 23 Downloading foo 2.0.0...'''); |
| 24 d.cacheDir({ |
| 25 "foo": "1.2.1" |
| 26 }).validate(); |
| 27 d.cacheDir({ |
| 28 "foo": "1.2.2" |
| 29 }).validate(); |
| 30 d.cacheDir({ |
| 31 "foo": "1.2.3" |
| 32 }).validate(); |
| 33 d.cacheDir({ |
| 34 "foo": "2.0.0" |
| 35 }).validate(); |
| 36 }); |
| 37 } |
OLD | NEW |