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

Unified Diff: tests/lib/math/math_parse_double_test.dart

Issue 10829459: Deprecate Math object in corelib in favor of dart:math library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address review comments. Created 8 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/lib/math/math2_test.dart ('k') | tests/lib/math/min_max_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/lib/math/math_parse_double_test.dart
diff --git a/tests/corelib/math_parse_double_test.dart b/tests/lib/math/math_parse_double_test.dart
similarity index 93%
rename from tests/corelib/math_parse_double_test.dart
rename to tests/lib/math/math_parse_double_test.dart
index f8bd1995062aaf864bfbaf784c025d501c3b2f91..4bf4a3262761fc823e41df7e81686ab13a6c1f6c 100644
--- a/tests/corelib/math_parse_double_test.dart
+++ b/tests/lib/math/math_parse_double_test.dart
@@ -1,4 +1,4 @@
-// Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
+// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
@@ -6,18 +6,11 @@
// class. This can easily be simplified once we get rid of the Math
// class entirely.
#library('math_parse_double_test');
-#import('dart:math', prefix: 'math');
-double parseDouble(String string) {
- num x = Math.parseDouble(string);
- num y = math.parseDouble(string);
- Expect.equals(x, y);
- return x;
-}
+#import('dart:math');
void parseDoubleThrowsFormatException(str) {
- Expect.throws(() => Math.parseDouble(str), (e) => e is FormatException);
- Expect.throws(() => math.parseDouble(str), (e) => e is FormatException);
+ Expect.throws(() => parseDouble(str), (e) => e is FormatException);
}
void main() {
« no previous file with comments | « tests/lib/math/math2_test.dart ('k') | tests/lib/math/min_max_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698