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

Unified Diff: pkg/analyzer/test/file_system/physical_resource_provider_test.dart

Issue 2411423003: Add prefix to path import to work around breaking change (Closed)
Patch Set: Created 4 years, 2 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: pkg/analyzer/test/file_system/physical_resource_provider_test.dart
diff --git a/pkg/analyzer/test/file_system/physical_resource_provider_test.dart b/pkg/analyzer/test/file_system/physical_resource_provider_test.dart
index 07b62e21622e5961858f702a4d7c44281c64dc43..39ac5dcfa4d41091f729dff256fc42aa28e82ac6 100644
--- a/pkg/analyzer/test/file_system/physical_resource_provider_test.dart
+++ b/pkg/analyzer/test/file_system/physical_resource_provider_test.dart
@@ -11,7 +11,7 @@ import 'dart:io' as io;
import 'package:analyzer/file_system/file_system.dart';
import 'package:analyzer/file_system/physical_file_system.dart';
import 'package:analyzer/src/generated/source_io.dart';
-import 'package:path/path.dart';
+import 'package:path/path.dart' as pathos;
import 'package:test/test.dart';
import 'package:test_reflective_loader/test_reflective_loader.dart';
import 'package:watcher/watcher.dart';
@@ -30,6 +30,9 @@ var _isFile = new isInstanceOf<File>();
var _isFileSystemException = new isInstanceOf<FileSystemException>();
var _isFolder = new isInstanceOf<Folder>();
+String join(String part1, [String part2, String part3]) =>
+ pathos.join(part1, part2, part3);
+
@reflectiveTest
class FileTest extends _BaseTest {
String path;
@@ -180,7 +183,7 @@ class FileTest extends _BaseTest {
}
void test_resolveSymbolicLinksSync_links() {
- Context pathContext = PhysicalResourceProvider.INSTANCE.pathContext;
+ pathos.Context pathContext = PhysicalResourceProvider.INSTANCE.pathContext;
String pathA = pathContext.join(tempPath, 'a');
String pathB = pathContext.join(pathA, 'b');
new io.Directory(pathB).createSync(recursive: true);
@@ -440,7 +443,7 @@ class PhysicalResourceProviderTest extends _BaseTest {
test_getFolder_trailingSeparator() {
String path = tempPath;
PhysicalResourceProvider provider = PhysicalResourceProvider.INSTANCE;
- Folder folder = provider.getFolder('$path$separator');
+ Folder folder = provider.getFolder('$path${pathos.separator}');
expect(folder.path, path);
}
« no previous file with comments | « pkg/analyzer/test/file_system/memory_file_system_test.dart ('k') | pkg/analyzer/test/generated/all_the_rest_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698