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

Unified Diff: pkg/analyzer/test/src/task/dart_test.dart

Issue 1410643003: Add a public API for the results of constant evaluation (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years, 2 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
« no previous file with comments | « pkg/analyzer/test/generated/all_the_rest_test.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/test/src/task/dart_test.dart
diff --git a/pkg/analyzer/test/src/task/dart_test.dart b/pkg/analyzer/test/src/task/dart_test.dart
index 22ec7c3f642f13204dee5d0b4e5aa13035d480ed..547df9709239495ccbf46d3b3713c666a5c8ac90 100644
--- a/pkg/analyzer/test/src/task/dart_test.dart
+++ b/pkg/analyzer/test/src/task/dart_test.dart
@@ -1267,7 +1267,7 @@ class D {
expect(evaluationResult.value.type, isNotNull);
expect(evaluationResult.value.type.name, 'D');
expect(evaluationResult.value.fields, contains('value'));
- expect(evaluationResult.value.fields['value'].intValue, 1);
+ expect(evaluationResult.value.fields['value'].toIntValue(), 1);
}
test_annotation_without_args() {
@@ -1285,7 +1285,7 @@ const x = 1;
// And check that it has the expected value.
expect(evaluationResult, isNotNull);
expect(evaluationResult.value, isNotNull);
- expect(evaluationResult.value.intValue, 1);
+ expect(evaluationResult.value.toIntValue(), 1);
}
test_circular_reference() {
@@ -1342,7 +1342,7 @@ const y = 1;
''');
expect(evaluationResult, isNotNull);
expect(evaluationResult.value, isNotNull);
- expect(evaluationResult.value.intValue, 2);
+ expect(evaluationResult.value.toIntValue(), 2);
}
test_external_const_factory() {
@@ -1368,7 +1368,7 @@ const x = 1;
''');
expect(evaluationResult, isNotNull);
expect(evaluationResult.value, isNotNull);
- expect(evaluationResult.value.intValue, 1);
+ expect(evaluationResult.value.toIntValue(), 1);
}
void _checkCircularities(
« no previous file with comments | « pkg/analyzer/test/generated/all_the_rest_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698