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

Unified Diff: tests/corelib/json_map_test.dart

Issue 1980663002: Make json-maps implement Map<String, dynamic>. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Changelog and test updates Created 3 years, 8 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/_internal/js_runtime/lib/convert_patch.dart ('k') | tests/corelib/map_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/corelib/json_map_test.dart
diff --git a/tests/corelib/json_map_test.dart b/tests/corelib/json_map_test.dart
index e4d46eecbed67e7c04de73ea1bdbeb6794e1d3d1..8524e0088d82832b15fcd4a3d83dc1d6634754d6 100644
--- a/tests/corelib/json_map_test.dart
+++ b/tests/corelib/json_map_test.dart
@@ -53,7 +53,6 @@ void test(bool revive) {
testToString();
testConcurrentModifications();
testType();
- testNonStringKeys();
testClear();
testListEntry();
@@ -300,23 +299,8 @@ void testConcurrentModifications() {
void testType() {
Expect.isTrue(jsonify({}) is Map);
- Expect.isTrue(jsonify({}) is HashMap);
- Expect.isTrue(jsonify({}) is LinkedHashMap);
-
Expect.isTrue(jsonify({}) is Map<String, dynamic>);
- Expect.isTrue(jsonify({}) is HashMap<String, dynamic>);
- Expect.isTrue(jsonify({}) is LinkedHashMap<String, dynamic>);
-
- Expect.isTrue(jsonify({}) is Map<int, dynamic>);
- Expect.isTrue(jsonify({}) is HashMap<int, dynamic>);
- Expect.isTrue(jsonify({}) is LinkedHashMap<int, dynamic>);
-}
-
-void testNonStringKeys() {
- Map map = jsonify({});
- map[1] = 2;
- Expect.equals(1, map.length);
- Expect.equals(2, map[1]);
+ Expect.isFalse(jsonify({}) is Map<int, dynamic>);
}
void testClear() {
« no previous file with comments | « sdk/lib/_internal/js_runtime/lib/convert_patch.dart ('k') | tests/corelib/map_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698