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

Side by Side Diff: tests/language/abstract_runtime_error_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) 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 import "package:expect/expect.dart";
6
5 // Test various conditions around instantiating an abstract class. 7 // Test various conditions around instantiating an abstract class.
6 8
7 // From The Dart Programming Langauge Specification, 11.11.1 "New": 9 // From The Dart Programming Langauge Specification, 11.11.1 "New":
8 // If q is a constructor of an abstract class then an 10 // If q is a constructor of an abstract class then an
9 // AbstractClassInstantiation- Error is thrown. 11 // AbstractClassInstantiation- Error is thrown.
10 12
11 13
12 abstract class Interface { 14 abstract class Interface {
13 void foo(); 15 void foo();
14 } 16 }
(...skipping 19 matching lines...) Expand all
34 } 36 }
35 37
36 void main() { 38 void main() {
37 Expect.throws(interface, isAbstractClassInstantiationError, 39 Expect.throws(interface, isAbstractClassInstantiationError,
38 "expected AbstractClassInstantiationError"); 40 "expected AbstractClassInstantiationError");
39 Expect.throws(abstractClass, isAbstractClassInstantiationError, 41 Expect.throws(abstractClass, isAbstractClassInstantiationError,
40 "expected AbstractClassInstantiationError"); 42 "expected AbstractClassInstantiationError");
41 Expect.stringEquals('ConcreteSubclass', '${new ConcreteSubclass()}'); 43 Expect.stringEquals('ConcreteSubclass', '${new ConcreteSubclass()}');
42 Expect.stringEquals('NonAbstractClass', '${new NonAbstractClass()}'); 44 Expect.stringEquals('NonAbstractClass', '${new NonAbstractClass()}');
43 } 45 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698