OLD | NEW |
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 import "package:expect/expect.dart"; | |
6 | |
7 // Test Parameter Intializer. | 5 // Test Parameter Intializer. |
8 | 6 |
9 | 7 |
10 class ParameterInitializer2Test { | 8 class ParameterInitializer2Test { |
11 static testMain() { | 9 static testMain() { |
12 var a = new A(123); | 10 var a = new A(123); |
13 Expect.equals(123, a.x); | 11 Expect.equals(123, a.x); |
14 | 12 |
15 var b = new B(123); | 13 var b = new B(123); |
16 Expect.equals(123, b.x); | 14 Expect.equals(123, b.x); |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
75 int y_; | 73 int y_; |
76 int w_; | 74 int w_; |
77 int z; | 75 int z; |
78 int az_; | 76 int az_; |
79 } | 77 } |
80 | 78 |
81 | 79 |
82 main() { | 80 main() { |
83 ParameterInitializer2Test.testMain(); | 81 ParameterInitializer2Test.testMain(); |
84 } | 82 } |
OLD | NEW |