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

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

Issue 10874051: Support self-referential package: imports with Pub. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Code review change Created 8 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 | « utils/tests/pub/pub_test.dart ('k') | utils/tests/pub/version_solver_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/tests/pub/test_pub.dart
diff --git a/utils/tests/pub/test_pub.dart b/utils/tests/pub/test_pub.dart
index cf80ebe837d1496f828c5a1dfdbe9c586aa9d08c..9fe67f0e00c7c46015046011d3081f8f37d96f8f 100644
--- a/utils/tests/pub/test_pub.dart
+++ b/utils/tests/pub/test_pub.dart
@@ -228,8 +228,12 @@ Descriptor pubspec(Map contents) {
* Describes a file named `pubspec.yaml` for an application package with the
* given [dependencies].
*/
-Descriptor appPubspec(List dependencies) =>
- pubspec({"dependencies": _dependencyListToMap(dependencies)});
+Descriptor appPubspec(List dependencies) {
+ return pubspec({
+ "name": "myapp",
+ "dependencies": _dependencyListToMap(dependencies)
+ });
+}
/**
* Describes a file named `pubspec.yaml` for a library package with the given
@@ -439,14 +443,13 @@ void run() {
// If an error occurs during testing, delete the sandbox, throw the error so
// that the test framework sees it, then finally call asyncDone so that the
// test framework knows we're done doing asynchronous stuff.
- cleanup().then((_) {
- registerException(error, future.stackTrace);
- asyncDone();
- });
+ cleanup().then((_) => registerException(error, future.stackTrace));
return true;
});
- future.chain((_) => cleanup()).then((_) => asyncDone());
+ future.chain((_) => cleanup()).then((_) {
+ asyncDone();
+ });
}
/**
« no previous file with comments | « utils/tests/pub/pub_test.dart ('k') | utils/tests/pub/version_solver_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698