| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add unit tests for cookies handling
Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data:
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #9965
Either:
- [X] There are tests for these changes OR
- [ ] These changes do not require tests because _____
Add unit tests for the `net` component about cookies. The tests are generated
with a new `mach update-net-cookies` command from this repo: https://github.com/abarth/http-state.
This PR also includes two trivial bug fixes about cookie handling.
From all the tests included, the following ones are currently failing:
- cookie_http_state::test_0003
- cookie_http_state::test_0006
- cookie_http_state::test_attribute0004
- cookie_http_state::test_attribute0005
- cookie_http_state::test_attribute0007
- cookie_http_state::test_attribute0008
- cookie_http_state::test_domain0017
- cookie_http_state::test_mozilla0001
- cookie_http_state::test_mozilla0002
- cookie_http_state::test_mozilla0003
- cookie_http_state::test_mozilla0005
- cookie_http_state::test_mozilla0007
- cookie_http_state::test_mozilla0009
- cookie_http_state::test_mozilla0010
- cookie_http_state::test_mozilla0013
`test_000[36]` and `test_mozilla*` are failing because there is currently no
method to clean a `net::cookie_storage` from expired cookies.
`test_attribute000[4578]` are failing because hyper does not parse the `Secure`
attribute correctly. I will open an issue on the upstream project.
`test_domain0017` fails because the TLD .org is not on the PUB_DOMAINS list.
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/11196)
<!-- Reviewable:end -->
|
| |
| |
| |
| |
| |
| | |
- Cookies with empty values are not to be ignored as per RFC6265
- A space should separate two cookie-pairs as per RFC6265 section
4.2.1
|
|/
|
|
| |
This fixes #11185.
|
| |
|
|
|
|
| |
profile_dir option is present
|
|
|
|
| |
profile_dir option is present
|
| |
|
|
|
|
|
| |
Changed to_string calls to to_owned calls
where was a need.
|
| |
|
|
|
|
| |
Part of https://github.com/servo/servo/issues/6041
|
| |
|
|
|
|
| |
Fixes #4476
|
| |
|
| |
|
| |
|
|
|
|
| |
incorrect cookie removal operation logic. Order the returned cookies according to the spec. Make cookie unit tests pass.
|
|
|
|
| |
Implement storage-related cookie behaviour such as domain and path matching that cookie-rs doesn't require. Remove stored cookies when an empty value is stored. Document cookie code.
|
|
|