| Index: test/utils.dart
|
| diff --git a/test/utils.dart b/test/utils.dart
|
| index 30a273abcde6e5a56589ad8c5ade7c617ed0a0c6..8fba63db529d9c838f5bd0e7e2675e41129319a1 100644
|
| --- a/test/utils.dart
|
| +++ b/test/utils.dart
|
| @@ -22,7 +22,13 @@ ScheduledProcess runFormatter([List<String> args]) {
|
| var formatterPath = p.join(
|
| p.dirname(p.fromUri(Platform.script)), "..", "bin", "format.dart");
|
|
|
| - args.insertAll(0, ["--package-root=${Platform.packageRoot}", formatterPath]);
|
| + args.insert(0, formatterPath);
|
| +
|
| + // Use the same package root, if there is one.
|
| + if (Platform.packageRoot.isNotEmpty) {
|
| + args.insert(0, "--package-root=${Platform.packageRoot}");
|
| + }
|
| +
|
| return new ScheduledProcess.start(Platform.executable, args);
|
| }
|
|
|
|
|