OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS 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 file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 import 'package:scheduled_test/scheduled_test.dart'; | 5 import 'package:scheduled_test/scheduled_test.dart'; |
6 | 6 |
7 import '../../descriptor.dart' as d; | 7 import '../../descriptor.dart' as d; |
8 import '../../test_pub.dart'; | 8 import '../../test_pub.dart'; |
9 | 9 |
10 main() { | 10 main() { |
(...skipping 12 matching lines...) Expand all Loading... |
23 pubGet(); | 23 pubGet(); |
24 | 24 |
25 // Clear the cache. We don't care about anything that was served during | 25 // Clear the cache. We don't care about anything that was served during |
26 // the initial get. | 26 // the initial get. |
27 globalServer.clearRequestedPaths(); | 27 globalServer.clearRequestedPaths(); |
28 | 28 |
29 // Run the solver again now that it's cached. | 29 // Run the solver again now that it's cached. |
30 pubGet(); | 30 pubGet(); |
31 | 31 |
32 d.cacheDir({"foo": "1.2.0"}).validate(); | 32 d.cacheDir({"foo": "1.2.0"}).validate(); |
33 d.packagesDir({"foo": "1.2.0"}).validate(); | 33 d.appPackagesFile({"foo": "1.2.0"}).validate(); |
34 | 34 |
35 // The get should not have done any network requests since the lock file is | 35 // The get should not have done any network requests since the lock file is |
36 // up to date. | 36 // up to date. |
37 globalServer.requestedPaths.then((paths) { | 37 globalServer.requestedPaths.then((paths) { |
38 expect(paths, isEmpty); | 38 expect(paths, isEmpty); |
39 }); | 39 }); |
40 }); | 40 }); |
41 } | 41 } |
OLD | NEW |