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

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

Issue 703963002: Use Element's source paths instead of URIs as a key in the index. (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/codec_test.dart
diff --git a/pkg/analysis_server/test/services/index/store/codec_test.dart b/pkg/analysis_server/test/services/index/store/codec_test.dart
index dd445a0cbede5567334dca833f92a0e3b7d560e0..50da07564fe4dc109b95124daee86a084dc2c6ee 100644
--- a/pkg/analysis_server/test/services/index/store/codec_test.dart
+++ b/pkg/analysis_server/test/services/index/store/codec_test.dart
@@ -107,15 +107,15 @@ class A {
PropertyAccessorElement getter = field.getter;
PropertyAccessorElement setter = field.setter;
{
- int id = codec.encode(getter);
+ int id = codec.encode(getter, false);
expect(codec.decode(context, id), getter);
}
{
- int id = codec.encode(setter);
+ int id = codec.encode(setter, false);
expect(codec.decode(context, id), setter);
}
{
- int id = codec.encode(field);
+ int id = codec.encode(field, false);
expect(codec.decode(context, id), field);
}
}
@@ -137,12 +137,12 @@ main() {
''');
{
LocalVariableElement element = findNodeElementAtString('bar; // A', null);
- int id = codec.encode(element);
+ int id = codec.encode(element, false);
expect(codec.decode(context, id), element);
}
{
LocalVariableElement element = findNodeElementAtString('bar; // B', null);
- int id = codec.encode(element);
+ int id = codec.encode(element, false);
expect(codec.decode(context, id), element);
}
// check strings, "foo" as a single string, no "foo@17" or "bar@35"
@@ -166,12 +166,12 @@ main() {
''');
{
LocalVariableElement element = findNodeElementAtString('foo; // A', null);
- int id = codec.encode(element);
+ int id = codec.encode(element, false);
expect(codec.decode(context, id), element);
}
{
LocalVariableElement element = findNodeElementAtString('foo; // B', null);
- int id = codec.encode(element);
+ int id = codec.encode(element, false);
expect(codec.decode(context, id), element);
}
// check strings, "foo" as a single string, no "foo@21" or "foo@47"
@@ -188,8 +188,8 @@ main() {
}
''');
LocalVariableElement element = findElement('foo');
- int id = codec.encode(element);
- expect(codec.encode(element), id);
+ int id = codec.encode(element, false);
+ expect(codec.encode(element, false), id);
expect(codec.decode(context, id), element);
// check strings
expect(stringCodec.nameToIndex, hasLength(3));

Powered by Google App Engine
This is Rietveld 408576698