OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 import "package:expect/expect.dart"; | 5 import "package:expect/expect.dart"; |
6 import 'dart:async'; | 6 import 'dart:async'; |
7 import 'dart:math'; | 7 import 'dart:math'; |
8 import 'dart:collection'; | 8 import 'dart:collection'; |
9 | 9 |
10 part '../../../sdk/lib/io/common.dart'; | 10 part '../../../sdk/lib/io/common.dart'; |
11 part "../../../sdk/lib/io/io_sink.dart"; | 11 part "../../../sdk/lib/io/io_sink.dart"; |
12 part "../../../sdk/lib/io/http.dart"; | 12 part "../../../sdk/lib/io/http.dart"; |
| 13 part "../../../sdk/lib/io/http_date.dart"; |
13 part "../../../sdk/lib/io/http_headers.dart"; | 14 part "../../../sdk/lib/io/http_headers.dart"; |
14 part "../../../sdk/lib/io/http_impl.dart"; | 15 part "../../../sdk/lib/io/http_impl.dart"; |
15 part "../../../sdk/lib/io/http_parser.dart"; | 16 part "../../../sdk/lib/io/http_parser.dart"; |
16 part "../../../sdk/lib/io/http_utils.dart"; | |
17 part "../../../sdk/lib/io/socket.dart"; | 17 part "../../../sdk/lib/io/socket.dart"; |
18 | 18 |
19 void testMultiValue() { | 19 void testMultiValue() { |
20 _HttpHeaders headers = new _HttpHeaders("1.1"); | 20 _HttpHeaders headers = new _HttpHeaders("1.1"); |
21 Expect.isNull(headers[HttpHeaders.PRAGMA]); | 21 Expect.isNull(headers[HttpHeaders.PRAGMA]); |
22 headers.add(HttpHeaders.PRAGMA, "pragma1"); | 22 headers.add(HttpHeaders.PRAGMA, "pragma1"); |
23 Expect.equals(1, headers[HttpHeaders.PRAGMA].length); | 23 Expect.equals(1, headers[HttpHeaders.PRAGMA].length); |
24 Expect.equals(1, headers["pragma"].length); | 24 Expect.equals(1, headers["pragma"].length); |
25 Expect.equals(1, headers["Pragma"].length); | 25 Expect.equals(1, headers["Pragma"].length); |
26 Expect.equals(1, headers["PRAGMA"].length); | 26 Expect.equals(1, headers["PRAGMA"].length); |
(...skipping 398 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
425 testIfModifiedSince(); | 425 testIfModifiedSince(); |
426 testHost(); | 426 testHost(); |
427 testEnumeration(); | 427 testEnumeration(); |
428 testHeaderValue(); | 428 testHeaderValue(); |
429 testContentType(); | 429 testContentType(); |
430 testContentTypeCache(); | 430 testContentTypeCache(); |
431 testCookie(); | 431 testCookie(); |
432 testInvalidCookie(); | 432 testInvalidCookie(); |
433 testHeaderLists(); | 433 testHeaderLists(); |
434 } | 434 } |
OLD | NEW |