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

Unified Diff: tests/language/stack_trace_test.dart

Issue 10891020: Update almost all tests (except co19) to use the new try-catch syntax. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Merge. Created 8 years, 4 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 | « tests/language/stack_overflow_test.dart ('k') | tests/language/statement_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/language/stack_trace_test.dart
diff --git a/tests/language/stack_trace_test.dart b/tests/language/stack_trace_test.dart
index ac507272ec34e031225cdcd4c63c7fac654fbde4..87c5815f699994621f89617c53a95312df60abd1 100644
--- a/tests/language/stack_trace_test.dart
+++ b/tests/language/stack_trace_test.dart
@@ -13,7 +13,7 @@ class Helper {
try {
i = func();
i = 10;
- } catch (MyException exception, var stacktrace) {
+ } on MyException catch (exception, stacktrace) {
i = 50;
print(exception.message_);
Expect.equals((stacktrace != null), true);
@@ -23,7 +23,7 @@ class Helper {
int j;
i = func1();
i = 200;
- } catch (MyException exception, var stacktrace) {
+ } on MyException catch (exception, stacktrace) {
i = 50;
print(exception.message_);
Expect.equals((stacktrace != null), true);
@@ -33,7 +33,7 @@ class Helper {
int j;
i = func2();
i = 200;
- } catch (MyException exception, var stacktrace) {
+ } on MyException catch (exception, stacktrace) {
i = 50;
print(exception.message_);
Expect.equals((stacktrace != null), true);
@@ -58,7 +58,7 @@ class Helper {
static int func1() {
try {
func();
- } catch (MyException exception) {
+ } on MyException catch (exception) {
throw new MyException("Exception Test for stack trace being printed");;
}
return 10;
@@ -67,7 +67,7 @@ class Helper {
static int func2() {
try {
func();
- } catch (MyException exception) {
+ } on MyException catch (exception) {
throw;
}
return 10;
« no previous file with comments | « tests/language/stack_overflow_test.dart ('k') | tests/language/statement_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698