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 // Dart test for testing access to private fields. | 5 // Dart test for testing access to private fields. |
6 part of PrivateTest; | |
7 | 6 |
8 main() { | 7 main() { |
9 testPrivateTopLevel(); | 8 testPrivateTopLevel(); |
10 testPrivateClasses(); | 9 testPrivateClasses(); |
11 } | 10 } |
12 | 11 |
13 void expectCatch(f) { | 12 void expectCatch(f) { |
14 bool threw = false; | 13 bool threw = false; |
15 try { | 14 try { |
16 f(); | 15 f(); |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 Expect.equals(42, c.field2a()); | 88 Expect.equals(42, c.field2a()); |
90 Expect.equals(99, LibOther3.c_field1b(c)); | 89 Expect.equals(99, LibOther3.c_field1b(c)); |
91 Expect.equals(99, c.field1b()); | 90 Expect.equals(99, c.field1b()); |
92 Expect.equals(1024, LibOther3.c_field2b(c)); | 91 Expect.equals(1024, LibOther3.c_field2b(c)); |
93 Expect.equals(1024, c.field2b()); | 92 Expect.equals(1024, c.field2b()); |
94 Expect.equals(499, c.field1c()); | 93 Expect.equals(499, c.field1c()); |
95 Expect.equals(99, c.field1d()); | 94 Expect.equals(99, c.field1d()); |
96 Expect.equals(499, _field1FromNewC4()); | 95 Expect.equals(499, _field1FromNewC4()); |
97 Expect.equals(42, _field2FromNewC4()); | 96 Expect.equals(42, _field2FromNewC4()); |
98 } | 97 } |
OLD | NEW |