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

Unified Diff: pkg/analysis_server/test/services/index/store/split_store_test.dart

Issue 738673002: Use shorter DartElementLocation. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 1 month 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/analysis_server/test/services/index/store/split_store_test.dart
diff --git a/pkg/analysis_server/test/services/index/store/split_store_test.dart b/pkg/analysis_server/test/services/index/store/split_store_test.dart
index ba994acd6a3a30a988225faf6dd6d88f687403ce..d5df66cf1c36ccd2e7d145a00ff34ce0f5f58b47 100644
--- a/pkg/analysis_server/test/services/index/store/split_store_test.dart
+++ b/pkg/analysis_server/test/services/index/store/split_store_test.dart
@@ -448,7 +448,8 @@ class _RelationKeyDataTest {
int elementId = 2;
{
element = new MockElement();
- ElementLocation location = new ElementLocationImpl.con3(['foo', 'bar']);
+ ElementLocation location =
+ new DartElementLocation('lib.dart', 'unit.dart', 42, ElementKind.CLASS);
when(element.location).thenReturn(location);
when(context.getElement(location)).thenReturn(element);
when(elementCodec.encode(element, anyBool)).thenReturn(elementId);
@@ -492,13 +493,13 @@ class _SplitIndexStoreTest {
Element elementC = new MockElement('elementC');
Element elementD = new MockElement('elementD');
ElementLocation elementLocationA =
- new ElementLocationImpl.con3(['/home/user/sourceA.dart', 'ClassA']);
+ new DartElementLocation('lib.dart', 'unitA.dart', 1, ElementKind.CLASS);
ElementLocation elementLocationB =
- new ElementLocationImpl.con3(['/home/user/sourceB.dart', 'ClassB']);
+ new DartElementLocation('lib.dart', 'unitB.dart', 2, ElementKind.CLASS);
ElementLocation elementLocationC =
- new ElementLocationImpl.con3(['/home/user/sourceC.dart', 'ClassC']);
+ new DartElementLocation('lib.dart', 'unitC.dart', 3, ElementKind.CLASS);
ElementLocation elementLocationD =
- new ElementLocationImpl.con3(['/home/user/sourceD.dart', 'ClassD']);
+ new DartElementLocation('lib.dart', 'unitD.dart', 4, ElementKind.CLASS);
HtmlElement htmlElementA = new MockHtmlElement();
HtmlElement htmlElementB = new MockHtmlElement();
LibraryElement libraryElement = new MockLibraryElement();

Powered by Google App Engine
This is Rietveld 408576698