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

Side by Side Diff: pkg/http/test/html/streamed_request_test.dart

Issue 334703004: pkg/http: updated unittest dependency, removed unused imports (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: changelog tweaks Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « pkg/http/pubspec.yaml ('k') | pkg/http/test/html/utils.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library http.test.html.streamed_request_test; 5 library http.test.html.streamed_request_test;
6 6
7 import 'dart:convert';
8
9 import 'package:http/http.dart' as http; 7 import 'package:http/http.dart' as http;
10 import 'package:http/browser_client.dart'; 8 import 'package:http/browser_client.dart';
11 import 'package:unittest/unittest.dart'; 9 import 'package:unittest/unittest.dart';
12 10
13 import 'utils.dart'; 11 import 'utils.dart';
14 12
15 void main() { 13 void main() {
16 group('contentLength', () { 14 group('contentLength', () {
17 test("works when it's set", () { 15 test("works when it's set", () {
18 var request = new http.StreamedRequest('POST', echoUrl); 16 var request = new http.StreamedRequest('POST', echoUrl);
(...skipping 11 matching lines...) Expand all
30 var request = new http.StreamedRequest('POST', echoUrl); 28 var request = new http.StreamedRequest('POST', echoUrl);
31 request.sink.add([1, 2, 3, 4, 5, 6, 7, 8, 9, 10]); 29 request.sink.add([1, 2, 3, 4, 5, 6, 7, 8, 9, 10]);
32 request.sink.close(); 30 request.sink.close();
33 31
34 return new BrowserClient().send(request).then((response) { 32 return new BrowserClient().send(request).then((response) {
35 expect(response.stream.toBytes(), 33 expect(response.stream.toBytes(),
36 completion(equals([1, 2, 3, 4, 5, 6, 7, 8, 9, 10]))); 34 completion(equals([1, 2, 3, 4, 5, 6, 7, 8, 9, 10])));
37 }); 35 });
38 }); 36 });
39 }); 37 });
40 } 38 }
OLDNEW
« no previous file with comments | « pkg/http/pubspec.yaml ('k') | pkg/http/test/html/utils.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698