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

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

Issue 10699068: Add numerous features to the Pub test infrastructure. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 6 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
Index: utils/tests/pub/pub_test.dart
diff --git a/utils/tests/pub/pub_test.dart b/utils/tests/pub/pub_test.dart
index 4bfb2a331d5f62cc7f588690d466238c2d92a592..d4ccfc0bc66686441bd70c2f192c4085dddb90c2 100644
--- a/utils/tests/pub/pub_test.dart
+++ b/utils/tests/pub/pub_test.dart
@@ -99,16 +99,18 @@ installCommand() {
file('pubspec.yaml', 'dependencies:\n foo:')
]).scheduleCreate();
+ schedulePub(args: ['install'],
+ output: '''
+ Dependencies installed!
+ ''');
+
dir(packagesPath, [
dir('foo', [
file('foo.dart', 'main() => "foo";')
])
]).scheduleValidate();
- runPub(args: ['install'],
- output: '''
- Dependencies installed!
- ''');
+ run();
});
test('adds a transitively dependent package', () {
@@ -128,6 +130,11 @@ installCommand() {
file('pubspec.yaml', 'dependencies:\n foo:')
]).scheduleCreate();
+ schedulePub(args: ['install'],
+ output: '''
+ Dependencies installed!
+ ''');
+
dir(packagesPath, [
dir('foo', [
file('foo.dart', 'main() => "foo";')
@@ -137,10 +144,7 @@ installCommand() {
])
]).scheduleValidate();
- runPub(args: ['install'],
- output: '''
- Dependencies installed!
- ''');
+ run();
});
test('checks out a package from Git', () {
@@ -157,14 +161,16 @@ dependencies:
''')
]).scheduleCreate();
+ schedulePub(args: ['install'],
+ output: const RegExp(@"Dependencies installed!$"));
+
dir(packagesPath, [
dir('foo', [
file('foo.dart', 'main() => "foo";')
])
]).scheduleValidate();
- runPub(args: ['install'],
- output: const RegExp(@"Dependencies installed!$"));
+ run();
});
});
@@ -191,6 +197,9 @@ dependencies:
''')
]).scheduleCreate();
+ schedulePub(args: ['install'],
+ output: const RegExp("Dependencies installed!\$"));
+
dir(packagesPath, [
dir('foo', [
file('foo.dart', 'main() => "foo";')
@@ -200,8 +209,7 @@ dependencies:
])
]).scheduleValidate();
- runPub(args: ['install'],
- output: const RegExp("Dependencies installed!\$"));
+ run();
});
});
@@ -219,6 +227,9 @@ dependencies:
''')
]).scheduleCreate();
+ schedulePub(args: ['install'],
+ output: const RegExp("Dependencies installed!\$"));
+
dir(cachePath, [
dir('repo', [
dir('localhost%583123', [
@@ -237,8 +248,7 @@ dependencies:
])
]).scheduleValidate();
- runPub(args: ['install'],
- output: const RegExp("Dependencies installed!\$"));
+ run();
});
test('checks out packages transitively from a pub server', () {
@@ -267,6 +277,9 @@ dependencies:
''')
]).scheduleCreate();
+ schedulePub(args: ['install'],
+ output: const RegExp("Dependencies installed!\$"));
+
dir(cachePath, [
dir('repo', [
dir('localhost%583123', [
@@ -307,8 +320,7 @@ dependencies:
])
]).scheduleValidate();
- runPub(args: ['install'],
- output: const RegExp("Dependencies installed!\$"));
+ run();
});
}

Powered by Google App Engine
This is Rietveld 408576698