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

Unified Diff: tests/language/src/InterfaceTest.dart

Issue 9582027: Some use of the new @static-clean and /// annotations in shared tests (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 10 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/src/InstanceFieldNegativeTest.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/language/src/InterfaceTest.dart
diff --git a/tests/language/src/InterfaceTest.dart b/tests/language/src/InterfaceTest.dart
index 2c2ed9cea8d26712111dd164564ff118815fe01b..f912bdb53187d41732e4182abebbb7957a50afd7 100644
--- a/tests/language/src/InterfaceTest.dart
+++ b/tests/language/src/InterfaceTest.dart
@@ -1,7 +1,7 @@
-// Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
+// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-// Dart test program for testing params.
+// Dart test program for testing Interfaces.
interface Ai {
int foo();
@@ -29,16 +29,14 @@ class InterfaceTest implements Ai, Aai, Abi, Baz, Bi {
InterfaceTest() {}
int foo() { return 1; }
+ // intentionally unimplemented methods
abstract beta();
abstract String beta1();
abstract String beta2(double d);
-
- static testMain() {
- var o = new Bi();
- Expect.equals(1, o.foo());
- }
}
main() {
- InterfaceTest.testMain();
+ // instantiate an abstract class
+ var o = new Bi(); /// static type error
+ Expect.equals(1, o.foo());
}
« no previous file with comments | « tests/language/src/InstanceFieldNegativeTest.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698