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

Unified Diff: pkg/analyzer/test/src/summary/resynthesize_test.dart

Issue 1995763003: Build top-level variables and property accessors lazily. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 7 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/src/summary/resynthesize_test.dart
diff --git a/pkg/analyzer/test/src/summary/resynthesize_test.dart b/pkg/analyzer/test/src/summary/resynthesize_test.dart
index e4f296e1d7d882c1cfe7ea0d397abe06c4c66cc4..85e6cce11aace21fc46522a094307c3b17d0edc9 100644
--- a/pkg/analyzer/test/src/summary/resynthesize_test.dart
+++ b/pkg/analyzer/test/src/summary/resynthesize_test.dart
@@ -260,13 +260,14 @@ abstract class AbstractResynthesizeTest extends AbstractSingleUnitTest {
compareUriReferencedElements(resynthesized, original, desc);
expect(resynthesized.source, original.source);
expect(resynthesized.librarySource, original.librarySource);
- expect(resynthesized.types.length, original.types.length);
+ expect(resynthesized.types.length, original.types.length, reason: 'types');
Paul Berry 2016/05/19 11:27:30 Please include `$desc` in the reason (e.g. `reason
scheglov 2016/05/19 16:54:57 Done.
for (int i = 0; i < resynthesized.types.length; i++) {
compareClassElements(
resynthesized.types[i], original.types[i], original.types[i].name);
}
expect(resynthesized.topLevelVariables.length,
- original.topLevelVariables.length);
+ original.topLevelVariables.length,
+ reason: 'topLevelVariables');
for (int i = 0; i < resynthesized.topLevelVariables.length; i++) {
String name = resynthesized.topLevelVariables[i].name;
compareTopLevelVariableElements(
@@ -275,25 +276,28 @@ abstract class AbstractResynthesizeTest extends AbstractSingleUnitTest {
.singleWhere((TopLevelVariableElement e) => e.name == name),
'variable $name');
}
- expect(resynthesized.functions.length, original.functions.length);
+ expect(resynthesized.functions.length, original.functions.length,
+ reason: 'functions');
for (int i = 0; i < resynthesized.functions.length; i++) {
compareFunctionElements(resynthesized.functions[i], original.functions[i],
'function ${original.functions[i].name}');
}
expect(resynthesized.functionTypeAliases.length,
- original.functionTypeAliases.length);
+ original.functionTypeAliases.length,
+ reason: 'functionTypeAliases');
for (int i = 0; i < resynthesized.functionTypeAliases.length; i++) {
compareFunctionTypeAliasElements(
resynthesized.functionTypeAliases[i],
original.functionTypeAliases[i],
original.functionTypeAliases[i].name);
}
- expect(resynthesized.enums.length, original.enums.length);
+ expect(resynthesized.enums.length, original.enums.length, reason: 'enums');
for (int i = 0; i < resynthesized.enums.length; i++) {
compareClassElements(
resynthesized.enums[i], original.enums[i], original.enums[i].name);
}
- expect(resynthesized.accessors.length, original.accessors.length);
+ expect(resynthesized.accessors.length, original.accessors.length,
+ reason: 'accessors');
for (int i = 0; i < resynthesized.accessors.length; i++) {
String name = resynthesized.accessors[i].name;
if (original.accessors[i].isGetter) {

Powered by Google App Engine
This is Rietveld 408576698