| 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"; | 5 import "package:expect/expect.dart"; |
| 6 | 6 |
| 7 class ConstListTest { | 7 class ConstListTest { |
| 8 | 8 |
| 9 static testMain() { | 9 static testMain() { |
| 10 List fixedList = new List(4); | 10 List fixedList = new List(4); |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 Expect.equals(4, growableList.removeLast()); | 27 Expect.equals(4, growableList.removeLast()); |
| 28 Expect.equals(false, fixedList == growableList); | 28 Expect.equals(false, fixedList == growableList); |
| 29 fixedList[3] = 0; | 29 fixedList[3] = 0; |
| 30 Expect.equals(false, fixedList == growableList); | 30 Expect.equals(false, fixedList == growableList); |
| 31 var a = [1, 2, 3.1]; | 31 var a = [1, 2, 3.1]; |
| 32 var b = [1, 2, 3.1]; | 32 var b = [1, 2, 3.1]; |
| 33 Expect.equals(false, a == b); | 33 Expect.equals(false, a == b); |
| 34 a = const [1, 2, 3.1]; | 34 a = const [1, 2, 3.1]; |
| 35 b = const [1, 2, 3.1]; | 35 b = const [1, 2, 3.1]; |
| 36 Expect.equals(true, a == b); | 36 Expect.equals(true, a == b); |
| 37 a = const <num>[1, 2, 3.1]; |
| 38 b = const [1, 2, 3.1]; |
| 39 Expect.equals(false, a == b); |
| 40 a = const <dynamic>[1, 2, 3.1]; |
| 41 b = const [1, 2, 3.1]; |
| 42 Expect.equals(true, a == b); |
| 37 } | 43 } |
| 38 } | 44 } |
| 39 | 45 |
| 40 main() { | 46 main() { |
| 41 ConstListTest.testMain(); | 47 ConstListTest.testMain(); |
| 42 } | 48 } |
| OLD | NEW |