Index: pkg/http/test/utils.dart |
diff --git a/pkg/http/test/utils.dart b/pkg/http/test/utils.dart |
index 7b42bec00163174423f894406575da2c02f1dfec..f9a73813ac83756dd26328b0174c8f67c34363e8 100644 |
--- a/pkg/http/test/utils.dart |
+++ b/pkg/http/test/utils.dart |
@@ -7,7 +7,6 @@ library test_utils; |
import 'dart:async'; |
import 'dart:convert'; |
import 'dart:io'; |
-import 'dart:json' as json; |
import 'package:http/src/byte_stream.dart'; |
import 'package:http/src/utils.dart'; |
@@ -96,7 +95,7 @@ Future startServer() { |
content['headers'][name] = values; |
}); |
- var body = json.stringify(content); |
+ var body = JSON.encode(content); |
response.contentLength = body.length; |
response.write(body); |
response.close(); |
@@ -154,7 +153,7 @@ class _Parse extends Matcher { |
var parsed; |
try { |
- parsed = json.parse(item); |
+ parsed = JSON.decode(item); |
} catch (e) { |
return false; |
} |