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

Side by Side Diff: tests/compiler/dart2js_foreign/native_class_inheritance3_test.dart

Issue 12212016: Remove Expect from core library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated latest tests. Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 // Test to see if resolving a hidden native class's method to noSuchMethod 5 // Test to see if resolving a hidden native class's method to noSuchMethod
6 // interferes with subsequent resolving of the method. This might happen if the 6 // interferes with subsequent resolving of the method. This might happen if the
7 // noSuchMethod is cached on Object.prototype. 7 // noSuchMethod is cached on Object.prototype.
8 8
9 import "package:expect/expect.dart";
9 import 'native_metadata.dart'; 10 import 'native_metadata.dart';
10 11
11 @Native("*A1") 12 @Native("*A1")
12 class A1 { 13 class A1 {
13 } 14 }
14 15
15 @Native("*B1") 16 @Native("*B1")
16 class B1 extends A1 { 17 class B1 extends A1 {
17 } 18 }
18 19
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 expectNoSuchMethod(action, note) { 96 expectNoSuchMethod(action, note) {
96 bool caught = false; 97 bool caught = false;
97 try { 98 try {
98 action(); 99 action();
99 } catch (ex) { 100 } catch (ex) {
100 caught = true; 101 caught = true;
101 Expect.isTrue(ex is NoSuchMethodError, note); 102 Expect.isTrue(ex is NoSuchMethodError, note);
102 } 103 }
103 Expect.isTrue(caught, note); 104 Expect.isTrue(caught, note);
104 } 105 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698