| OLD | NEW |
| 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 | |
| 7 // Test that field initializers are evaluated in the right order. | 5 // Test that field initializers are evaluated in the right order. |
| 8 | 6 |
| 9 int counter = 0; | 7 int counter = 0; |
| 10 | 8 |
| 11 class Mark { | 9 class Mark { |
| 12 static StringBuffer buffer; | 10 static StringBuffer buffer; |
| 13 Mark(value) { | 11 Mark(value) { |
| 14 buffer.write('$value.'); | 12 buffer.write('$value.'); |
| 15 } | 13 } |
| 16 } | 14 } |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 new InheritOneField())); | 67 new InheritOneField())); |
| 70 Expect.equals('b.bi.a.', run(() => | 68 Expect.equals('b.bi.a.', run(() => |
| 71 new InheritOneField.init())); | 69 new InheritOneField.init())); |
| 72 Expect.equals('b.a.ai.', run(() => | 70 Expect.equals('b.a.ai.', run(() => |
| 73 new InheritOneField.superWithInit())); | 71 new InheritOneField.superWithInit())); |
| 74 Expect.equals('b.bi.a.ai.', run(() => | 72 Expect.equals('b.bi.a.ai.', run(() => |
| 75 new InheritOneField.initWithSuperInit())); | 73 new InheritOneField.initWithSuperInit())); |
| 76 Expect.equals('b.a.ai.bi.', run(() => | 74 Expect.equals('b.a.ai.bi.', run(() => |
| 77 new InheritOneField.initWithSuperInit2())); | 75 new InheritOneField.initWithSuperInit2())); |
| 78 } | 76 } |
| OLD | NEW |