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

Unified Diff: test/test_pub.dart

Issue 1277633004: Auto-run "pub get" more for "pub run". (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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/run/runs_shorthand_app_in_dependency_test.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/test_pub.dart
diff --git a/test/test_pub.dart b/test/test_pub.dart
index 8dcebc7940d8251bd0dab66d071ee4936da139d5..86376eafb1ba80e3a73f529d41504c4444e9bb97 100644
--- a/test/test_pub.dart
+++ b/test/test_pub.dart
@@ -354,11 +354,19 @@ void pubDowngrade({Iterable<String> args, output, error, warning,
/// "pub run".
///
/// Returns the `pub run` process.
-ScheduledProcess pubRun({bool global: false, Iterable<String> args}) {
+ScheduledProcess pubRun({bool shouldGetFirst: false, bool global: false,
+ Iterable<String> args}) {
var pubArgs = global ? ["global", "run"] : ["run"];
pubArgs.addAll(args);
var pub = startPub(args: pubArgs);
+ if (shouldGetFirst) {
+ pub.stdout.expect(consumeThrough(anyOf([
+ "Got dependencies!",
+ matches(new RegExp(r"^Changed \d+ dependenc"))
+ ])));
+ }
+
// Loading sources and transformers isn't normally printed, but the pub test
// infrastructure runs pub in verbose mode, which enables this.
pub.stdout.expect(consumeWhile(startsWith("Loading")));
« no previous file with comments | « test/run/runs_shorthand_app_in_dependency_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698