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

Unified Diff: pkg/analyzer/test/generated/resolver_test.dart

Issue 1771153002: Type check for-in statements. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Update to latest on master. Created 4 years, 9 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/generated/resolver_test.dart
diff --git a/pkg/analyzer/test/generated/resolver_test.dart b/pkg/analyzer/test/generated/resolver_test.dart
index beef6de7ea2dc8cfa14fc74bfd0fe03bc85c7afc..1a6c459aa6b6f2a92c3abaf4d78a5b9ea58023c3 100644
--- a/pkg/analyzer/test/generated/resolver_test.dart
+++ b/pkg/analyzer/test/generated/resolver_test.dart
@@ -8371,6 +8371,19 @@ class ResolverTestCase extends EngineTestCase {
}
/**
+ * Asserts that [code] has errors with the given error codes.
+ *
+ * Like [assertErrors], but takes a string of source code.
+ */
+ // TODO(rnystrom): Use this in more tests that have the same structure.
+ void assertErrorsInCode(String code, List<ErrorCode> errors) {
+ Source source = addSource(code);
+ computeLibrarySourceErrors(source);
+ assertErrors(source, errors);
+ verify([source]);
+ }
+
+ /**
* Assert that no errors have been reported against the given source.
*
* @param source the source against which no errors should have been reported
@@ -8382,6 +8395,17 @@ class ResolverTestCase extends EngineTestCase {
}
/**
+ * Asserts that [code] has no errors or warnings.
+ */
+ // TODO(rnystrom): Use this in more tests that have the same structure.
+ void assertNoErrorsInCode(String code) {
+ Source source = addSource(code);
+ computeLibrarySourceErrors(source);
+ assertNoErrors(source);
+ verify([source]);
+ }
+
+ /**
* Cache the source file content in the source factory but don't add the source to the analysis
* context. The file path should be absolute.
*

Powered by Google App Engine
This is Rietveld 408576698