Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11)

Side by Side Diff: tests/language/double_to_string_as_exponential_test.dart

Issue 12743005: Revert "Remove Expect from core library." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Reupload (first upload failed). Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 // Test basic integer operations. 4 // Test basic integer operations.
5 5
6 import "package:expect/expect.dart";
7
8 main() { 6 main() {
9 Expect.equals("1e+0", (1.0).toStringAsExponential()); 7 Expect.equals("1e+0", (1.0).toStringAsExponential());
10 Expect.equals("1.1e+1", (11.0).toStringAsExponential()); 8 Expect.equals("1.1e+1", (11.0).toStringAsExponential());
11 Expect.equals("1.12e+2", (112.0).toStringAsExponential()); 9 Expect.equals("1.12e+2", (112.0).toStringAsExponential());
12 Expect.equals("1e+0", (1.0).toStringAsExponential(null)); 10 Expect.equals("1e+0", (1.0).toStringAsExponential(null));
13 Expect.equals("1.1e+1", (11.0).toStringAsExponential(null)); 11 Expect.equals("1.1e+1", (11.0).toStringAsExponential(null));
14 Expect.equals("1.12e+2", (112.0).toStringAsExponential(null)); 12 Expect.equals("1.12e+2", (112.0).toStringAsExponential(null));
15 Expect.equals("1e+0", (1.0).toStringAsExponential(0)); 13 Expect.equals("1e+0", (1.0).toStringAsExponential(0));
16 Expect.equals("1e+1", (11.0).toStringAsExponential(0)); 14 Expect.equals("1e+1", (11.0).toStringAsExponential(0));
17 Expect.equals("1e+2", (112.0).toStringAsExponential(0)); 15 Expect.equals("1e+2", (112.0).toStringAsExponential(0));
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 Expect.equals("0.00e+0", (0.0).toStringAsExponential(2)); 89 Expect.equals("0.00e+0", (0.0).toStringAsExponential(2));
92 Expect.equals("1e+1", (11.2356).toStringAsExponential(0)); 90 Expect.equals("1e+1", (11.2356).toStringAsExponential(0));
93 Expect.equals("1.1236e+1", (11.2356).toStringAsExponential(4)); 91 Expect.equals("1.1236e+1", (11.2356).toStringAsExponential(4));
94 Expect.equals("1.1236e-4", (0.000112356).toStringAsExponential(4)); 92 Expect.equals("1.1236e-4", (0.000112356).toStringAsExponential(4));
95 Expect.equals("-1.1236e-4", (-0.000112356).toStringAsExponential(4)); 93 Expect.equals("-1.1236e-4", (-0.000112356).toStringAsExponential(4));
96 Expect.equals("1.12356e-4", (0.000112356).toStringAsExponential()); 94 Expect.equals("1.12356e-4", (0.000112356).toStringAsExponential());
97 Expect.equals("-1.12356e-4", (-0.000112356).toStringAsExponential()); 95 Expect.equals("-1.12356e-4", (-0.000112356).toStringAsExponential());
98 Expect.equals("1.12356e-4", (0.000112356).toStringAsExponential(null)); 96 Expect.equals("1.12356e-4", (0.000112356).toStringAsExponential(null));
99 Expect.equals("-1.12356e-4", (-0.000112356).toStringAsExponential(null)); 97 Expect.equals("-1.12356e-4", (-0.000112356).toStringAsExponential(null));
100 } 98 }
OLDNEW
« no previous file with comments | « tests/language/double_to_string_as_exponential3_test.dart ('k') | tests/language/double_to_string_as_fixed2_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698