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

Side by Side Diff: test/deps_test.dart

Issue 1274763010: Improve the output of "pub deps". (Closed) Base URL: git@github.com:dart-lang/pub.git@master
Patch Set: Created 5 years, 4 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 | « lib/src/command/deps.dart ('k') | no next file » | 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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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() {
11 setUp(() { 11 setUp(() {
12 servePackages((builder) { 12 servePackages((builder) {
13 builder.serve("normal", "1.2.3", deps: { 13 builder.serve("normal", "1.2.3", deps: {
14 "transitive": "any", 14 "transitive": "any",
15 "circular_a": "any" 15 "circular_a": "any"
16 }); 16 });
17 builder.serve("transitive", "1.2.3", deps: {"shared": "any"}); 17 builder.serve("transitive", "1.2.3", deps: {"shared": "any"});
18 builder.serve("shared", "1.2.3", deps: {"other": "any"}); 18 builder.serve("shared", "1.2.3", deps: {"other": "any"});
19 builder.serve("unittest", "1.2.3", deps: {"shared": "any"}); 19 builder.serve("unittest", "1.2.3", deps: {"shared": "any"});
20 builder.serve("other", "1.0.0"); 20 builder.serve("other", "1.0.0", deps: {"myapp": "any"});
21 builder.serve("overridden", "1.0.0"); 21 builder.serve("overridden", "1.0.0");
22 builder.serve("overridden", "2.0.0"); 22 builder.serve("overridden", "2.0.0");
23 builder.serve("override_only", "1.2.3"); 23 builder.serve("override_only", "1.2.3");
24 builder.serve("circular_a", "1.2.3", deps: {"circular_b": "any"}); 24 builder.serve("circular_a", "1.2.3", deps: {"circular_b": "any"});
25 builder.serve("circular_b", "1.2.3", deps: {"circular_a": "any"}); 25 builder.serve("circular_b", "1.2.3", deps: {"circular_a": "any"});
26 }); 26 });
27 27
28 d.dir("from_path", [ 28 d.dir("from_path", [
29 d.libDir("from_path"), 29 d.libDir("from_path"),
30 d.libPubspec("from_path", "1.2.3") 30 d.libPubspec("from_path", "1.2.3")
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 dev dependencies: 62 dev dependencies:
63 - unittest 1.2.3 [shared] 63 - unittest 1.2.3 [shared]
64 64
65 dependency overrides: 65 dependency overrides:
66 - overridden 2.0.0 66 - overridden 2.0.0
67 - override_only 1.2.3 67 - override_only 1.2.3
68 68
69 transitive dependencies: 69 transitive dependencies:
70 - circular_a 1.2.3 [circular_b] 70 - circular_a 1.2.3 [circular_b]
71 - circular_b 1.2.3 [circular_a] 71 - circular_b 1.2.3 [circular_a]
72 - other 1.0.0 72 - other 1.0.0 [myapp]
73 - shared 1.2.3 [other] 73 - shared 1.2.3 [other]
74 - transitive 1.2.3 [shared] 74 - transitive 1.2.3 [shared]
75 '''); 75 ''');
76 }); 76 });
77 77
78 integration("lists dependencies in list form", () { 78 integration("lists dependencies in list form", () {
79 pubGet(); 79 pubGet();
80 schedulePub(args: ['deps', '--style', 'list'], output: ''' 80 schedulePub(args: ['deps', '--style', 'list'], output: '''
81 myapp 0.0.0 81 myapp 0.0.0
82 82
(...skipping 11 matching lines...) Expand all
94 dependency overrides: 94 dependency overrides:
95 - overridden 2.0.0 95 - overridden 2.0.0
96 - override_only 1.2.3 96 - override_only 1.2.3
97 97
98 transitive dependencies: 98 transitive dependencies:
99 - circular_a 1.2.3 99 - circular_a 1.2.3
100 - circular_b any 100 - circular_b any
101 - circular_b 1.2.3 101 - circular_b 1.2.3
102 - circular_a any 102 - circular_a any
103 - other 1.0.0 103 - other 1.0.0
104 - myapp any
104 - shared 1.2.3 105 - shared 1.2.3
105 - other any 106 - other any
106 - transitive 1.2.3 107 - transitive 1.2.3
107 - shared any 108 - shared any
108 '''); 109 ''');
109 }); 110 });
110 111
111 integration("lists dependencies in tree form", () { 112 integration("lists dependencies in tree form", () {
112 pubGet(); 113 pubGet();
113 schedulePub(args: ['deps'], output: ''' 114 schedulePub(args: ['deps'], output: '''
114 myapp 0.0.0 115 myapp 0.0.0
115 |-- from_path 1.2.3 116 |-- from_path 1.2.3
116 |-- normal 1.2.3 117 |-- normal 1.2.3
117 | |-- circular_a 1.2.3 118 | |-- circular_a 1.2.3
118 | | '-- circular_b 1.2.3 119 | | '-- circular_b 1.2.3
119 | | '-- circular_a... 120 | | '-- circular_a...
120 | '-- transitive 1.2.3 121 | '-- transitive 1.2.3
121 | '-- shared... 122 | '-- shared...
122 |-- overridden 2.0.0 123 |-- overridden 2.0.0
123 |-- override_only 1.2.3 124 |-- override_only 1.2.3
124 '-- unittest 1.2.3 125 '-- unittest 1.2.3
125 '-- shared 1.2.3 126 '-- shared 1.2.3
126 '-- other 1.0.0 127 '-- other 1.0.0
128 '-- myapp...
127 '''); 129 ''');
128 }); 130 });
129 } 131 }
OLDNEW
« no previous file with comments | « lib/src/command/deps.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698