Skip to content

Conversation

@joemcgill
Copy link
Member

This adjusts the "No private directive present in cache control when user not logged in" test so they won't fail if the headers don't contain a cache-control key at all.

While trying to debug why E2E tests have been flaky, I noticed that the logged out test for cache control headers was often failing locally because the response headers don't have a cache-control key at all, resulting in a Matcher error: received value must not be null nor undefined failure. This adjusts the tests to use expect.not.objectContaining() instead.

Trac ticket: https://core.trac.wordpress.org/ticket/21938


This Pull Request is for code review only. Please keep all other discussion in the Trac ticket. Do not merge this Pull Request. See GitHub Pull Requests for Code Review in the Core Handbook for more details.

This adjusts the "No private directive present in cache control when user not logged in" test so they won't fail if the headers don't contain a `cache-control` key at all.
@joemcgill joemcgill requested a review from johnbillion July 4, 2023 02:32
@joemcgill joemcgill marked this pull request as ready for review July 4, 2023 02:32
@johnbillion
Copy link
Member

The tests are running fine for me locally with this change, but CI still isn't happy. I'll get this in anyway.

@johnbillion
Copy link
Member

@johnbillion johnbillion closed this Jul 4, 2023
@joemcgill
Copy link
Member Author

Thanks @johnbillion. Agree with you that this doesn't fix the timeouts that we're seeing in CI, but this does make it easier to run these tests locally while debugging.

@joemcgill joemcgill deleted the update/21938-e2e-tests branch October 11, 2024 19:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants