OLD | NEW |
(Empty) | |
| 1 /* |
| 2 * Copyright 2014 Google Inc. All rights reserved. |
| 3 * |
| 4 * Use of this source code is governed by a BSD-style |
| 5 * license that can be found in the LICENSE file or at |
| 6 * https://developers.google.com/open-source/licenses/bsd |
| 7 */ |
| 8 |
| 9 library charted.test.core; |
| 10 |
| 11 import 'dart:html' show document, Element; |
| 12 import 'package:unittest/unittest.dart'; |
| 13 import 'package:charted/core/utils.dart'; |
| 14 |
| 15 import 'dart:math' as math; |
| 16 |
| 17 part 'lists_test.dart'; |
| 18 part 'namespace_test.dart'; |
| 19 part 'color_test.dart'; |
| 20 part 'math_test.dart'; |
| 21 part 'object_factory_test.dart'; |
| 22 |
| 23 coreTests() { |
| 24 group('isNullOrEmpty()', () { |
| 25 test('returns true when the object is null or empty', () { |
| 26 expect(isNullOrEmpty(null), isTrue); |
| 27 expect(isNullOrEmpty(''), isTrue); |
| 28 expect(isNullOrEmpty({}), isTrue); |
| 29 expect(isNullOrEmpty([]), isTrue); |
| 30 }); |
| 31 test('returns false when the object is not null or empty', () { |
| 32 expect(isNullOrEmpty([3]), isFalse); |
| 33 }); |
| 34 }); |
| 35 |
| 36 testLists(); |
| 37 testNamespace(); |
| 38 testColor(); |
| 39 testMath(); |
| 40 testObjectFactory(); |
| 41 } |
OLD | NEW |