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

Unified Diff: pkg/analyzer/test/src/task/strong/strong_test_helper.dart

Issue 1395853004: FYI: add strong mode checking to error verifier's task (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: format 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/src/task/dart_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/strong/strong_test_helper.dart
diff --git a/pkg/analyzer/test/src/task/strong/strong_test_helper.dart b/pkg/analyzer/test/src/task/strong/strong_test_helper.dart
index 8bd564ae7a5bf0374d32a965cb0e08ab621795a4..e9b54974273f3d1e2e5d07956a5ea380ca7da9b9 100644
--- a/pkg/analyzer/test/src/task/strong/strong_test_helper.dart
+++ b/pkg/analyzer/test/src/task/strong/strong_test_helper.dart
@@ -21,7 +21,6 @@ import 'package:logging/logging.dart'; // TODO(jmesserly): remove
import 'package:source_span/source_span.dart'; // TODO(jmesserly): remove
import 'package:unittest/unittest.dart';
-
/// Run the checker on a program with files contents as indicated in
/// [testFiles].
///
@@ -76,9 +75,8 @@ void testChecker(String name, Map<String, String> testFiles) {
context.resolveCompilationUnit2(mainSource, mainSource);
var collector = new _ErrorCollector();
- var errorReporter = new ErrorReporter(collector, mainSource);
- var checker = new CodeChecker(new TypeRules(context.typeProvider),
- errorReporter);
+ var checker =
+ new CodeChecker(new TypeRules(context.typeProvider), collector);
// Extract expectations from the comments in the test files, and
// check that all errors we emit are included in the expected map.
@@ -90,7 +88,6 @@ void testChecker(String name, Map<String, String> testFiles) {
var source = unit.source;
if (source.uri.scheme == 'dart') continue;
- errorReporter.source = unit.source;
var librarySource = context.getLibrariesContaining(source).single;
var resolved = context.resolveCompilationUnit2(source, librarySource);
@@ -286,7 +283,6 @@ class _ErrorExpectation {
String toString() => '$level $typeName';
}
-
/// Dart SDK which contains a mock implementation of the SDK libraries. May be
/// used to speed up execution when most of the core libraries is not needed.
class MockDartSdk implements DartSdk {
@@ -456,7 +452,6 @@ final Map<String, String> mockSdkSources = {
''',
};
-
/// Returns all libraries transitively imported or exported from [start].
List<LibraryElement> reachableLibraries(LibraryElement start) {
var results = <LibraryElement>[];
« no previous file with comments | « pkg/analyzer/test/src/task/dart_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698