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

Unified Diff: tests/corelib/uri_base_test.dart

Issue 23686021: Add property base to the Uri class (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed more review comments Created 7 years, 3 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 | « sdk/lib/core/uri.dart ('k') | tests/html/uri_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/corelib/uri_base_test.dart
diff --git a/tests/compiler/dart2js_extra/constant_fold_number_dart2_j_s_test.dart b/tests/corelib/uri_base_test.dart
similarity index 58%
copy from tests/compiler/dart2js_extra/constant_fold_number_dart2_j_s_test.dart
copy to tests/corelib/uri_base_test.dart
index aab61d722206c722719646d16f179a50f4d31fca..0954aabeeed9b373a164d69b7673d8e529a7600d 100644
--- a/tests/compiler/dart2js_extra/constant_fold_number_dart2_j_s_test.dart
+++ b/tests/corelib/uri_base_test.dart
@@ -1,15 +1,15 @@
// 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.
-// This test is making sure we don't try to constant fold numbers
-// where the semantics differ at compile-time (Dart) and runtime (JS).
import "package:expect/expect.dart";
-foo() => 0.0;
-bar() => 0;
-
main() {
- Expect.equals(foo(), bar());
- Expect.equals(0.0, 0);
+ try {
+ Uri base = Uri.base;
+ Expect.isTrue(Uri.base.scheme == "file" || Uri.base.scheme == "http");
+ } on UnsupportedError catch (e) {
+ Expect.isTrue(
+ e.toString().contains("'Uri.base' is not supported"));
+ }
}
« no previous file with comments | « sdk/lib/core/uri.dart ('k') | tests/html/uri_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698