| Index: tests/standalone/io/http_headers_test.dart
|
| diff --git a/tests/standalone/io/http_headers_test.dart b/tests/standalone/io/http_headers_test.dart
|
| index ad891b153b7afd1b74d3e479ad2666ef95f7e8d6..94fb19c428653db1da7062a6e263e78c5b8b8d2c 100644
|
| --- a/tests/standalone/io/http_headers_test.dart
|
| +++ b/tests/standalone/io/http_headers_test.dart
|
| @@ -366,67 +366,64 @@ void testCookie() {
|
|
|
| Cookie cookie;
|
| cookie = new Cookie(name, value);
|
| - Expect.equals("$name=$value", cookie.toString());
|
| + Expect.equals("$name=$value; HttpOnly", cookie.toString());
|
| DateTime date = new DateTime.utc(2014, DateTime.JANUARY, 5, 23, 59, 59, 0);
|
| cookie.expires = date;
|
| checkCookie(cookie, "$name=$value"
|
| - "; Expires=Sun, 05 Jan 2014 23:59:59 GMT");
|
| + "; Expires=Sun, 05 Jan 2014 23:59:59 GMT"
|
| + "; HttpOnly");
|
| cookie.maxAge = 567;
|
| checkCookie(cookie, "$name=$value"
|
| "; Expires=Sun, 05 Jan 2014 23:59:59 GMT"
|
| - "; Max-Age=567");
|
| + "; Max-Age=567"
|
| + "; HttpOnly");
|
| cookie.domain = "example.com";
|
| checkCookie(cookie, "$name=$value"
|
| "; Expires=Sun, 05 Jan 2014 23:59:59 GMT"
|
| "; Max-Age=567"
|
| - "; Domain=example.com");
|
| + "; Domain=example.com"
|
| + "; HttpOnly");
|
| cookie.path = "/xxx";
|
| checkCookie(cookie, "$name=$value"
|
| "; Expires=Sun, 05 Jan 2014 23:59:59 GMT"
|
| "; Max-Age=567"
|
| "; Domain=example.com"
|
| - "; Path=/xxx");
|
| + "; Path=/xxx"
|
| + "; HttpOnly");
|
| cookie.secure = true;
|
| checkCookie(cookie, "$name=$value"
|
| "; Expires=Sun, 05 Jan 2014 23:59:59 GMT"
|
| "; Max-Age=567"
|
| "; Domain=example.com"
|
| "; Path=/xxx"
|
| - "; Secure");
|
| - cookie.httpOnly = true;
|
| + "; Secure"
|
| + "; HttpOnly");
|
| + cookie.httpOnly = false;
|
| checkCookie(cookie, "$name=$value"
|
| "; Expires=Sun, 05 Jan 2014 23:59:59 GMT"
|
| "; Max-Age=567"
|
| "; Domain=example.com"
|
| "; Path=/xxx"
|
| - "; Secure"
|
| - "; HttpOnly");
|
| + "; Secure");
|
| cookie.expires = null;
|
| checkCookie(cookie, "$name=$value"
|
| "; Max-Age=567"
|
| "; Domain=example.com"
|
| "; Path=/xxx"
|
| - "; Secure"
|
| - "; HttpOnly");
|
| + "; Secure");
|
| cookie.maxAge = null;
|
| checkCookie(cookie, "$name=$value"
|
| "; Domain=example.com"
|
| "; Path=/xxx"
|
| - "; Secure"
|
| - "; HttpOnly");
|
| + "; Secure");
|
| cookie.domain = null;
|
| checkCookie(cookie, "$name=$value"
|
| "; Path=/xxx"
|
| - "; Secure"
|
| - "; HttpOnly");
|
| + "; Secure");
|
| cookie.path = null;
|
| checkCookie(cookie, "$name=$value"
|
| - "; Secure"
|
| - "; HttpOnly");
|
| + "; Secure");
|
| cookie.secure = false;
|
| - checkCookie(cookie, "$name=$value"
|
| - "; HttpOnly");
|
| - cookie.httpOnly = false;
|
| checkCookie(cookie, "$name=$value");
|
| }
|
| test("name", "value");
|
|
|