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

Side by Side Diff: tests/language/is_not_class2_test.dart

Issue 2771453003: Format all tests. (Closed)
Patch Set: Format files Created 3 years, 8 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
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 // Dart test program for catch that we expect a class after an 'is'. 'aa' is a 5 // Dart test program for catch that we expect a class after an 'is'. 'aa' is a
6 // malformed type and a type error should be thrown upon test. 6 // malformed type and a type error should be thrown upon test.
7 7
8 import 'package:expect/expect.dart'; 8 import 'package:expect/expect.dart';
9 9
10 class A { 10 class A {
11 const A(); 11 const A();
12 } 12 }
13 13
14 class IsNotClass2NegativeTest { 14 class IsNotClass2NegativeTest {
15 static testMain() { 15 static testMain() {
16 var a = new A(); 16 var a = new A();
17 var aa = new A(); 17 var aa = new A();
18 18
19 if (a is aa) { // static warning 19 if (a is aa) {
20 // static warning
20 return 0; 21 return 0;
21 } 22 }
22 return 0; 23 return 0;
23 } 24 }
24 } 25 }
25 26
26 main() { 27 main() {
27 Expect.throws(IsNotClass2NegativeTest.testMain, (e) => e is TypeError); 28 Expect.throws(IsNotClass2NegativeTest.testMain, (e) => e is TypeError);
28 } 29 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698