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

Unified Diff: sdk/lib/_internal/pub_generated/test/dependency_override_test.dart

Issue 557563002: Store the async-await compiled pub code directly in the repo. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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: sdk/lib/_internal/pub_generated/test/dependency_override_test.dart
diff --git a/sdk/lib/_internal/pub/test/dependency_override_test.dart b/sdk/lib/_internal/pub_generated/test/dependency_override_test.dart
similarity index 74%
copy from sdk/lib/_internal/pub/test/dependency_override_test.dart
copy to sdk/lib/_internal/pub_generated/test/dependency_override_test.dart
index 4e47e24f6a9aafa2da9d4277b47ae6ca00fe4d0c..6d7e979f1c7cb0871c7f69cfb582b2aca5e0e6b2 100644
--- a/sdk/lib/_internal/pub/test/dependency_override_test.dart
+++ b/sdk/lib/_internal/pub_generated/test/dependency_override_test.dart
@@ -1,12 +1,6 @@
-// Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
import 'package:path/path.dart' as path;
-
import 'descriptor.dart' as d;
import 'test_pub.dart';
-
main() {
initConfig();
forBothPubGetAndUpgrade((command) {
@@ -16,9 +10,7 @@ main() {
builder.serve("foo", "2.0.0");
builder.serve("foo", "3.0.0");
});
-
- d.dir(appPath, [
- d.pubspec({
+ d.dir(appPath, [d.pubspec({
"name": "myapp",
"dependencies": {
"foo": ">2.0.0"
@@ -26,49 +18,39 @@ main() {
"dependency_overrides": {
"foo": "<3.0.0"
}
- })
- ]).create();
-
+ })]).create();
pubCommand(command);
-
d.packagesDir({
"foo": "2.0.0"
}).validate();
});
-
integration("treats override as implicit dependency", () {
servePackages((builder) {
builder.serve("foo", "1.0.0");
});
-
- d.dir(appPath, [
- d.pubspec({
+ d.dir(appPath, [d.pubspec({
"name": "myapp",
"dependency_overrides": {
"foo": "any"
}
- })
- ]).create();
-
+ })]).create();
pubCommand(command);
-
d.packagesDir({
"foo": "1.0.0"
}).validate();
});
-
integration("ignores other constraints on overridden package", () {
servePackages((builder) {
builder.serve("foo", "1.0.0");
builder.serve("foo", "2.0.0");
builder.serve("foo", "3.0.0");
builder.serve("bar", "1.0.0", pubspec: {
- "dependencies": {"foo": "5.0.0-nonexistent"}
+ "dependencies": {
+ "foo": "5.0.0-nonexistent"
+ }
});
});
-
- d.dir(appPath, [
- d.pubspec({
+ d.dir(appPath, [d.pubspec({
"name": "myapp",
"dependencies": {
"bar": "any"
@@ -76,43 +58,31 @@ main() {
"dependency_overrides": {
"foo": "<3.0.0"
}
- })
- ]).create();
-
+ })]).create();
pubCommand(command);
-
d.packagesDir({
"foo": "2.0.0",
"bar": "1.0.0"
}).validate();
});
-
integration("warns about overridden dependencies", () {
servePackages((builder) {
builder.serve("foo", "1.0.0");
builder.serve("bar", "1.0.0");
});
-
- d.dir("baz", [
- d.libDir("baz"),
- d.libPubspec("baz", "0.0.1")
- ]).create();
-
- d.dir(appPath, [
- d.pubspec({
+ d.dir("baz", [d.libDir("baz"), d.libPubspec("baz", "0.0.1")]).create();
+ d.dir(appPath, [d.pubspec({
"name": "myapp",
"dependency_overrides": {
"foo": "any",
"bar": "any",
- "baz": {"path": "../baz"}
+ "baz": {
+ "path": "../baz"
+ }
}
- })
- ]).create();
-
+ })]).create();
var bazPath = path.join("..", "baz");
-
- schedulePub(args: [command.name], output: command.success, error:
- """
+ schedulePub(args: [command.name], output: command.success, error: """
Warning: You are using these overridden dependencies:
! bar 1.0.0
! baz 0.0.1 from path $bazPath
@@ -120,4 +90,4 @@ main() {
""");
});
});
-}
+}

Powered by Google App Engine
This is Rietveld 408576698