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

Unified Diff: test/descriptor.dart

Issue 2377063002: Make "--no-packages-dir" the default. (Closed)
Patch Set: Created 4 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
Index: test/descriptor.dart
diff --git a/test/descriptor.dart b/test/descriptor.dart
index d4855be06af4abc9a50c2d340bfc5a4423b00504..b55844c51c1d1adc8914fe8fd6d3a27d9c24340d 100644
--- a/test/descriptor.dart
+++ b/test/descriptor.dart
@@ -203,3 +203,11 @@ DirectoryDescriptor appDir([Map dependencies]) =>
/// path to a path dependency, relative to the application directory.
Descriptor packagesFile([Map<String, String> dependencies]) =>
new PackagesFileDescriptor(dependencies);
+
+/// Describes a `.packages` file in the application directory, including the
+/// implicit entry for the app itself.
+Descriptor appPackagesFile(Map<String, String> dependencies) {
+ var copied = new Map<String, String>.from(dependencies);
nweiz 2016/09/28 20:01:21 Are these type annotations required? I thought the
Bob Nystrom 2016/09/29 00:21:26 Doesn't seem like it. Would you rather I leave it
nweiz 2016/09/29 00:32:41 Yeah, that's what I do.
Bob Nystrom 2016/09/29 00:56:41 Done.
+ copied["myapp"] = ".";
+ return dir(appPath, [packagesFile(copied)]);
+}

Powered by Google App Engine
This is Rietveld 408576698