| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | |
| 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. | |
| 4 | |
| 5 // Tests of literals (and imports, return, ==, and static methods). | |
| 6 import 'expect.dart'; | |
| 7 | |
| 8 test0() { | |
| 9 return 'Hello, world!'; | |
| 10 } | |
| 11 | |
| 12 test1() { | |
| 13 return 42; | |
| 14 } | |
| 15 | |
| 16 test2() { | |
| 17 return 2.71828; | |
| 18 } | |
| 19 | |
| 20 test3() { | |
| 21 return 6.022e23; | |
| 22 } | |
| 23 | |
| 24 test4() { | |
| 25 return true; | |
| 26 } | |
| 27 | |
| 28 test5() { | |
| 29 return false; | |
| 30 } | |
| 31 | |
| 32 test6() { | |
| 33 return 1405006117752879898543142606244511569936384000000000; | |
| 34 } | |
| 35 | |
| 36 main() { | |
| 37 Expect.isTrue(test0() == 'Hello, world!'); | |
| 38 Expect.isTrue(test1() == 42); | |
| 39 Expect.isTrue(test2() == 2.71828); | |
| 40 Expect.isTrue(test3() == 6.022e23); | |
| 41 Expect.isTrue(test4()); | |
| 42 Expect.isTrue(test5() == false); | |
| 43 Expect.isTrue( | |
| 44 test6() == 1405006117752879898543142606244511569936384000000000); | |
| 45 } | |
| OLD | NEW |