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

Side by Side Diff: tests/vm/dart/isolate_unhandled_exception_uri_helper.dart

Issue 11595002: Fix new isolate_unhandled_exception tests to make them compatible for dartium testing. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tests/vm/dart/isolate_unhandled_exception_test2.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library isolate_unhandled_exception_uri_helper;
6
5 import 'dart:isolate'; 7 import 'dart:isolate';
6 8
7 // Isolate script that throws an uncaught exception, which is caught by an 9 // Isolate script that throws an uncaught exception, which is caught by an
8 // uncaught exception handler. 10 // uncaught exception handler.
9 11
10 void main() { 12 void main() {
11 port.receive((message, replyTo) { 13 port.receive((message, replyTo) {
12 if (message == 'throw exception') { 14 if (message == 'throw exception') {
13 throw new RuntimeError('ignore this exception'); 15 throw new RuntimeError('ignore this exception');
14 } 16 }
15 replyTo.call('hello'); 17 replyTo.call('hello');
16 port.close(); 18 port.close();
17 }); 19 });
18 } 20 }
19 21
20 bool _unhandledExceptionCallback(IsolateUnhandledException e) { 22 bool _unhandledExceptionCallback(IsolateUnhandledException e) {
21 return e.source.message == 'ignore this exception'; 23 return e.source.message == 'ignore this exception';
22 } 24 }
OLDNEW
« no previous file with comments | « tests/vm/dart/isolate_unhandled_exception_test2.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698