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

Unified Diff: pkg/analyzer/test/generated/test_support.dart

Issue 981283003: Change all sources associated with changed files (issue 22680) (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments Created 5 years, 9 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/generated/test_support.dart
diff --git a/pkg/analyzer/test/generated/test_support.dart b/pkg/analyzer/test/generated/test_support.dart
index c59d37577bcf790379d78dfb04ffbf03ff448b8c..e5a05d06a128c068b412c7366959ec1167c607fa 100644
--- a/pkg/analyzer/test/generated/test_support.dart
+++ b/pkg/analyzer/test/generated/test_support.dart
@@ -615,3 +615,32 @@ class TestSource extends Source {
_contents = value;
}
}
+
+class TestSourceWithUri extends TestSource {
+ final Uri uri;
+
+ TestSourceWithUri(String path, this.uri, [String content])
+ : super(path, content);
+
+ UriKind get uriKind {
+ if (uri == null) {
+ return UriKind.FILE_URI;
+ } else if (uri.scheme == 'dart') {
+ return UriKind.DART_URI;
+ } else if (uri.scheme == 'package') {
+ return UriKind.PACKAGE_URI;
+ }
+ return UriKind.FILE_URI;
+ }
+
+ bool operator ==(Object other) {
+ if (other is TestSource) {
+ return other.uri == uri;
+ }
+ return false;
+ }
+
+ Uri resolveRelativeUri(Uri uri) {
+ return this.uri.resolveUri(uri);
+ }
+}

Powered by Google App Engine
This is Rietveld 408576698