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

Side by Side Diff: utils/tests/pub/pub_install_test.dart

Issue 11043026: Don't warn on the absence of "lib" in the root package. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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 | Annotate | Revision Log
« no previous file with comments | « utils/pub/io.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) 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 #library('pub_tests'); 5 #library('pub_tests');
6 6
7 #import('dart:io'); 7 #import('dart:io');
8 8
9 #import('test_pub.dart'); 9 #import('test_pub.dart');
10 #import('../../../pkg/unittest/unittest.dart'); 10 #import('../../../pkg/unittest/unittest.dart');
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 ]).scheduleCreate(); 88 ]).scheduleCreate();
89 89
90 schedulePub(args: ['install'], 90 schedulePub(args: ['install'],
91 error: const RegExp(r'Warning: Package "foo" does not have a "lib" ' 91 error: const RegExp(r'Warning: Package "foo" does not have a "lib" '
92 'directory.'), 92 'directory.'),
93 output: const RegExp(r"Dependencies installed!$")); 93 output: const RegExp(r"Dependencies installed!$"));
94 94
95 run(); 95 run();
96 }); 96 });
97 97
98 test('does not warn if the root package lacks a "lib" directory', () {
99 dir(appPath, [
100 appPubspec([])
101 ]).scheduleCreate();
102
103 schedulePub(args: ['install'],
104 error: '',
105 output: const RegExp(r"Dependencies installed!$"));
106
107 run();
108 });
109
98 test('overwrites the existing packages directory', () { 110 test('overwrites the existing packages directory', () {
99 dir(appPath, [ 111 dir(appPath, [
100 appPubspec([]), 112 appPubspec([]),
101 dir('packages', [ 113 dir('packages', [
102 dir('foo'), 114 dir('foo'),
103 dir('myapp'), 115 dir('myapp'),
104 ]), 116 ]),
105 libDir('myapp') 117 libDir('myapp')
106 ]).scheduleCreate(); 118 ]).scheduleCreate();
107 119
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
243 schedulePub(args: ['install'], 255 schedulePub(args: ['install'],
244 error: ''' 256 error: '''
245 Warning: Package "myapp_name" is using a deprecated layout. 257 Warning: Package "myapp_name" is using a deprecated layout.
246 See http://www.dartlang.org/docs/pub-package-manager/package-layout.html for details. 258 See http://www.dartlang.org/docs/pub-package-manager/package-layout.html for details.
247 ''', 259 ''',
248 output: const RegExp(r"Dependencies installed!$")); 260 output: const RegExp(r"Dependencies installed!$"));
249 261
250 run(); 262 run();
251 }); 263 });
252 } 264 }
OLDNEW
« no previous file with comments | « utils/pub/io.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698