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

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

Issue 14449004: Clean up various ways we find paths in pub. (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/utils.dart ('k') | sdk/lib/_internal/pub/test/test_pub.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/pub/test/real_version_test.dart
diff --git a/sdk/lib/_internal/pub/test/real_version_test.dart b/sdk/lib/_internal/pub/test/real_version_test.dart
index b87a324d4070212ed4196b26138aae8cb0a73e31..50857a4dc3fc55f47adefcd5eeb53588cc9e6310 100644
--- a/sdk/lib/_internal/pub/test/real_version_test.dart
+++ b/sdk/lib/_internal/pub/test/real_version_test.dart
@@ -6,6 +6,8 @@ library pub_tests;
import 'dart:io';
+import '../lib/src/sdk.dart' as sdk;
+
import 'package:pathos/path.dart' as path;
import 'package:scheduled_test/scheduled_process.dart';
import 'package:scheduled_test/scheduled_test.dart';
@@ -28,9 +30,8 @@ main() {
// the built SDK directory, and not the live pub code directly in the repo.
integration('parse the real SDK "version" file', () {
// Get the path to the pub binary in the SDK.
- var dartPath = new Options().executable;
- var pubPath = path.join(path.dirname(dartPath), "pub");
- if (Platform.operatingSystem == "windows") pubPath = '$pubPath.bat';
+ var pubPath = path.join(sdk.rootDirectory, 'bin',
+ Platform.operatingSystem == "windows" ? "pub.bat" : "pub");
var pub = new ScheduledProcess.start(pubPath, ['version']);
expect(pub.nextLine(), completion(startsWith("Pub")));
« no previous file with comments | « sdk/lib/_internal/pub/lib/src/utils.dart ('k') | sdk/lib/_internal/pub/test/test_pub.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698