Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(748)

Side by Side Diff: test/get/git/doesnt_fetch_if_nothing_changes_test.dart

Issue 2377063002: Make "--no-packages-dir" the default. (Closed)
Patch Set: Revise again. Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « test/get/git/different_repo_name_test.dart ('k') | test/get/git/lock_version_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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:path/path.dart' as p; 5 import 'package:path/path.dart' as p;
6 import 'package:pub/src/io.dart'; 6 import 'package:pub/src/io.dart';
7 import 'package:scheduled_test/scheduled_test.dart'; 7 import 'package:scheduled_test/scheduled_test.dart';
8 8
9 import '../../descriptor.dart' as d; 9 import '../../descriptor.dart' as d;
10 import '../../test_pub.dart'; 10 import '../../test_pub.dart';
11 11
12 main() { 12 main() {
13 integration("doesn't re-fetch a repository if nothing changes", () { 13 integration("doesn't re-fetch a repository if nothing changes", () {
14 ensureGit(); 14 ensureGit();
15 15
16 var repo = d.git('foo.git', [ 16 var repo = d.git('foo.git', [
17 d.libDir('foo'), 17 d.libDir('foo'),
18 d.libPubspec('foo', '1.0.0') 18 d.libPubspec('foo', '1.0.0')
19 ]); 19 ]);
20 repo.create(); 20 repo.create();
21 21
22 d.appDir({ 22 d.appDir({
23 "foo": {"git": {"url": "../foo.git"}} 23 "foo": {"git": {"url": "../foo.git"}}
24 }).create(); 24 }).create();
25 25
26 pubGet(); 26 // TODO(rnystrom): Remove "--packages-dir" and validate using the
27 // ".packages" file instead of looking in the "packages" directory.
28 pubGet(args: ["--packages-dir"]);
27 29
28 d.dir(packagesPath, [ 30 d.dir(packagesPath, [
29 d.dir('foo', [ 31 d.dir('foo', [
30 d.file('foo.dart', 'main() => "foo";') 32 d.file('foo.dart', 'main() => "foo";')
31 ]) 33 ])
32 ]).validate(); 34 ]).validate();
33 35
34 // Delete the repo. This will cause "pub get" to fail if it tries to 36 // Delete the repo. This will cause "pub get" to fail if it tries to
35 // re-fetch. 37 // re-fetch.
36 schedule(() => deleteEntry(p.join(sandboxDir, 'foo.git'))); 38 schedule(() => deleteEntry(p.join(sandboxDir, 'foo.git')));
37 39
38 pubGet(); 40 // TODO(rnystrom): Remove "--packages-dir" and validate using the
41 // ".packages" file instead of looking in the "packages" directory.
42 pubGet(args: ["--packages-dir"]);
39 43
40 d.dir(packagesPath, [ 44 d.dir(packagesPath, [
41 d.dir('foo', [ 45 d.dir('foo', [
42 d.file('foo.dart', 'main() => "foo";') 46 d.file('foo.dart', 'main() => "foo";')
43 ]) 47 ])
44 ]).validate(); 48 ]).validate();
45 }); 49 });
46 } 50 }
OLDNEW
« no previous file with comments | « test/get/git/different_repo_name_test.dart ('k') | test/get/git/lock_version_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698