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

Unified Diff: utils/tests/pub/pub_uploader_test.dart

Issue 12504006: Make IOSink implement StringSink (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed second round of review comments 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/standalone/io/stream_pipe_test.dart ('k') | utils/tests/pub/test_pub.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/tests/pub/pub_uploader_test.dart
diff --git a/utils/tests/pub/pub_uploader_test.dart b/utils/tests/pub/pub_uploader_test.dart
index d8f8721ed89c7d25802feb9875de3d68a8553bd1..3cbb997cced0b08fe69d84bd005eb7c20829e673 100644
--- a/utils/tests/pub/pub_uploader_test.dart
+++ b/utils/tests/pub/pub_uploader_test.dart
@@ -1,4 +1,4 @@
-// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
+// Copyright (c) 2013, 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.
@@ -58,7 +58,7 @@ main() {
expect(new String.fromCharCodes(bodyBytes), equals('email=email'));
response.headers.contentType = new ContentType("application", "json");
- response.addString(json.stringify({
+ response.write(json.stringify({
'success': {'message': 'Good job!'}
}));
response.close();
@@ -77,7 +77,7 @@ main() {
server.handle('DELETE', '/packages/pkg/uploaders/email.json',
(request, response) {
response.headers.contentType = new ContentType("application", "json");
- response.addString(json.stringify({
+ response.write(json.stringify({
'success': {'message': 'Good job!'}
}));
response.close();
@@ -97,7 +97,7 @@ main() {
server.handle('POST', '/packages/test_pkg/uploaders.json',
(request, response) {
response.headers.contentType = new ContentType("application", "json");
- response.addString(json.stringify({
+ response.write(json.stringify({
'success': {'message': 'Good job!'}
}));
response.close();
@@ -115,7 +115,7 @@ main() {
server.handle('POST', '/packages/pkg/uploaders.json', (request, response) {
response.statusCode = 400;
response.headers.contentType = new ContentType("application", "json");
- response.addString(json.stringify({
+ response.write(json.stringify({
'error': {'message': 'Bad job!'}
}));
response.close();
@@ -135,7 +135,7 @@ main() {
(request, response) {
response.statusCode = 400;
response.headers.contentType = new ContentType("application", "json");
- response.addString(json.stringify({
+ response.write(json.stringify({
'error': {'message': 'Bad job!'}
}));
response.close();
@@ -151,7 +151,7 @@ main() {
var pub = startPubUploader(server, ['--package', 'pkg', 'add', 'email']);
server.handle('POST', '/packages/pkg/uploaders.json', (request, response) {
- response.addString("{not json");
+ response.write("{not json");
response.close();
});
@@ -167,7 +167,7 @@ main() {
server.handle('DELETE', '/packages/pkg/uploaders/email.json',
(request, response) {
- response.addString("{not json");
+ response.write("{not json");
response.close();
});
« no previous file with comments | « tests/standalone/io/stream_pipe_test.dart ('k') | utils/tests/pub/test_pub.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698