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 #library('ElementTest'); | 5 #library('ElementTest'); |
6 #import('../../../../lib/unittest/unittest.dart'); | 6 #import('../../lib/unittest/unittest.dart'); |
7 #import('../../../../lib/unittest/html_config.dart'); | 7 #import('../../lib/unittest/html_config.dart'); |
8 #import('dart:html'); | 8 #import('dart:html'); |
9 | 9 |
10 expectLargeRect(ClientRect rect) { | 10 expectLargeRect(ClientRect rect) { |
11 Expect.equals(rect.top, 0); | 11 Expect.equals(rect.top, 0); |
12 Expect.equals(rect.left, 0); | 12 Expect.equals(rect.left, 0); |
13 Expect.isTrue(rect.width > 100); | 13 Expect.isTrue(rect.width > 100); |
14 Expect.isTrue(rect.height > 100); | 14 Expect.isTrue(rect.height > 100); |
15 Expect.equals(rect.bottom, rect.top + rect.height); | 15 Expect.equals(rect.bottom, rect.top + rect.height); |
16 Expect.equals(rect.right, rect.left + rect.width); | 16 Expect.equals(rect.right, rect.left + rect.width); |
17 } | 17 } |
(...skipping 872 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
890 classes.intersection(['foo', 'qux', 'baz'])); | 890 classes.intersection(['foo', 'qux', 'baz'])); |
891 }); | 891 }); |
892 | 892 |
893 test('clear', () { | 893 test('clear', () { |
894 final classes = makeClassSet(); | 894 final classes = makeClassSet(); |
895 classes.clear(); | 895 classes.clear(); |
896 Expect.setEquals([], classes); | 896 Expect.setEquals([], classes); |
897 }); | 897 }); |
898 }); | 898 }); |
899 } | 899 } |
OLD | NEW |