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

Unified Diff: utils/tests/pub/pub_install_test.dart

Issue 10952015: Delete the packages/ directory before installing new packages to it. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « utils/pub/entrypoint.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/tests/pub/pub_install_test.dart
diff --git a/utils/tests/pub/pub_install_test.dart b/utils/tests/pub/pub_install_test.dart
index 01f192ae57e385bec93173a67bc618d84e25c1c8..d9e803daae37f5a77b38c84ac0b065f699f7b78c 100644
--- a/utils/tests/pub/pub_install_test.dart
+++ b/utils/tests/pub/pub_install_test.dart
@@ -93,6 +93,27 @@ main() {
run();
});
+ test('overwrites the existing packages directory', () {
+ dir(appPath, [
+ appPubspec([]),
+ dir('packages', [
+ dir('foo'),
+ dir('myapp'),
+ ]),
+ libDir('myapp')
+ ]).scheduleCreate();
+
+ schedulePub(args: ['install'],
+ output: const RegExp(@"Dependencies installed!$"));
+
+ dir(packagesPath, [
+ nothing('foo'),
+ dir('myapp', [file('myapp.dart', 'main() => "myapp";')])
+ ]).scheduleValidate();
+
+ run();
+ });
+
group('creates a packages directory in', () {
test('"test/" and its subdirectories', () {
dir(appPath, [
« no previous file with comments | « utils/pub/entrypoint.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698