Skip to content

Commit 4587eca

Browse files
pqCommit Queue
authored andcommitted
[element model] migrate top_level_inference_test
Change-Id: I615b4b461dd574c1ff471f561ce334b4dd0371bc Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/401965 Reviewed-by: Brian Wilkerson <[email protected]> Commit-Queue: Brian Wilkerson <[email protected]>
1 parent ef8bf7d commit 4587eca

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

pkg/analyzer/analyzer_use_new_elements.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,6 @@ test/src/summary/elements/type_inference_test.dart
210210
test/src/summary/elements_base.dart
211211
test/src/summary/macro_test.dart
212212
test/src/summary/resolved_ast_printer.dart
213-
test/src/summary/top_level_inference_test.dart
214213
test/src/task/strong/dart2_inference_test.dart
215214
test/src/task/strong/inferred_type_test.dart
216215
test/src/utilities/extensions/analysis_session_test.dart

pkg/analyzer/test/src/summary/top_level_inference_test.dart

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ var b1 = a[1];
123123
var t = (int p) {};
124124
''');
125125
assertType(
126-
findElement.topVar('t').type,
126+
findElement2.topVar('t').type,
127127
'Null Function(int)',
128128
);
129129
}
@@ -134,7 +134,7 @@ var a = 0;
134134
var t = (int p) => (a = 1);
135135
''');
136136
assertType(
137-
findElement.topVar('t').type,
137+
findElement2.topVar('t').type,
138138
'int Function(int)',
139139
);
140140
}
@@ -144,7 +144,7 @@ var t = (int p) => (a = 1);
144144
var t = (int a, b,int c, d) => 0;
145145
''');
146146
assertType(
147-
findElement.topVar('t').type,
147+
findElement2.topVar('t').type,
148148
'int Function(int, dynamic, int, dynamic)',
149149
);
150150
}
@@ -21240,6 +21240,6 @@ library
2124021240
var analysisSession = contextFor(testFile).currentSession;
2124121241
var result = await analysisSession.getUnitElement(testFile.path);
2124221242
result as UnitElementResult;
21243-
return result.element.library as LibraryElementImpl;
21243+
return result.fragment.element as LibraryElementImpl;
2124421244
}
2124521245
}

0 commit comments

Comments
 (0)