| <!doctype html> |
| <html> |
| <head> |
| <meta charset=utf-8> |
| <title>Test max-age attribute parsing</title> |
| <meta name=help href="https://tools.ietf.org/html/rfc6265#section-5.3.2"> |
| <meta name="timeout" content="long"> |
| <script src="/resources/testharness.js"></script> |
| <script src="/resources/testharnessreport.js"></script> |
| <script src="/cookies/resources/cookie-test.js"></script> |
| </head> |
| <body> |
| <div id=log></div> |
| <script> |
| // TODO: there is more to test here, these tests capture the old |
| // ported http-state tests. Feel free to delete this comment when more |
| // are added. |
| const maxAgeTests = [ |
| { |
| cookie: "test=1; Max-Age=50,399", |
| expected: "test=1", |
| name: "Ignore max-age attribute with invalid non-zero-digit (containing a comma)", |
| }, |
| ]; |
| |
| for (const test of maxAgeTests) { |
| httpCookieTest(test.cookie, test.expected, test.name); |
| } |
| </script> |
| </body> |
| </html> |