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

Unified Diff: dart/tests/compiler/dart2js/resolver_test.dart

Issue 836313002: Remove dependencies on reportFatalError from tests. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 5 years, 11 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 | « dart/tests/compiler/dart2js/mock_compiler.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/tests/compiler/dart2js/resolver_test.dart
diff --git a/dart/tests/compiler/dart2js/resolver_test.dart b/dart/tests/compiler/dart2js/resolver_test.dart
index 653a12dd8a69078ba0a527290f4a11461224072f..6f488bc02a9a74c03b679a16d4a9b3f3170d12aa 100644
--- a/dart/tests/compiler/dart2js/resolver_test.dart
+++ b/dart/tests/compiler/dart2js/resolver_test.dart
@@ -15,6 +15,9 @@ import 'package:compiler/src/dart_types.dart';
import 'package:compiler/src/elements/modelx.dart';
import 'link_helper.dart';
+import "package:compiler/src/dart2jslib.dart" show
+ CompilerCancelledException;
+
Node buildIdentifier(String name) => new Identifier(scan(name));
Node buildInitialization(String name) =>
@@ -278,7 +281,14 @@ Future testThis() {
new CollectingTreeElements(funElement)));
FunctionExpression function =
(funElement as FunctionElementX).parseNode(compiler);
- visitor.visit(function.body);
+ try {
+ visitor.visit(function.body);
+ } on CompilerCancelledException catch (_) {
+ // Ignored.
+
+ // TODO(ahe): Don't ignore CompilerCancelledException, instead, fix
+ // pkg/compiler/lib/src/resolution/members.dart.
+ }
Expect.equals(0, compiler.warnings.length);
Expect.equals(1, compiler.errors.length);
Expect.equals(MessageKind.NO_INSTANCE_AVAILABLE,
« no previous file with comments | « dart/tests/compiler/dart2js/mock_compiler.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698