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

Unified Diff: sdk/lib/_internal/pub/test/test_pub.dart

Issue 13966011: Put a snapshot of pub in the SDK. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Code review changes. Created 7 years, 8 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 | « sdk/lib/_internal/pub/lib/src/pub.dart ('k') | tools/create_sdk.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/pub/test/test_pub.dart
diff --git a/sdk/lib/_internal/pub/test/test_pub.dart b/sdk/lib/_internal/pub/test/test_pub.dart
index ff10ba3067b7d4e545ad69c67775629703d1a930..b978d54bfa017c586ab4a03e3547c50a0f025325 100644
--- a/sdk/lib/_internal/pub/test/test_pub.dart
+++ b/sdk/lib/_internal/pub/test/test_pub.dart
@@ -389,22 +389,12 @@ ScheduledProcess startPub({List args, Future<Uri> tokenEndpoint}) {
description: args.isEmpty ? 'pub' : 'pub ${args.first}');
}
-/// Whether pub is running from within the Dart SDK, as opposed to from the Dart
-/// source repository.
-bool get _runningFromSdk =>
- fileExists(relativeToPub(path.join('..', '..', '..', '..', 'version')));
-
// TODO(nweiz): use the built-in mechanism for accessing this once it exists
// (issue 9119).
/// The path to the `packages` directory from which pub loads its dependencies.
String get _packageRoot {
- if (_runningFromSdk) {
- return path.absolute(relativeToPub(
- path.join('..', '..', '..', '..', 'packages')));
- } else {
- return path.absolute(path.join(
- path.dirname(new Options().executable), '..', '..', 'packages'));
- }
+ return path.absolute(path.join(
+ path.dirname(new Options().executable), '..', '..', 'packages'));
}
/// Skips the current test if Git is not installed. This validates that the
« no previous file with comments | « sdk/lib/_internal/pub/lib/src/pub.dart ('k') | tools/create_sdk.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698