Twstokes/automate manual test cases#334
Draft
twstokes wants to merge 17 commits intotest/automate-manual-test-casesfrom
Draft
Twstokes/automate manual test cases#334twstokes wants to merge 17 commits intotest/automate-manual-test-casesfrom
twstokes wants to merge 17 commits intotest/automate-manual-test-casesfrom
Conversation
d7e2b59 to
15264f3
Compare
d2f5105 to
fb7c78d
Compare
15264f3 to
5d110c5
Compare
Replace the E2E test commands with Docker availability checks to determine if/where Docker is installed on the mac queue agents. Removes the build-react dependency so the step runs immediately.
The `default` (Linux) queue has Docker for wp-env but is missing system libraries (libatk, etc.) that Chromium needs. Run `sudo npx playwright install-deps chromium` as a top-level pipeline command to install them via apt-get without interactive prompts.
f3cff05 to
21678e5
Compare
sudo is available on the default Linux queue (Docker install confirmed it), so the hang was likely apt-get prompting interactively. Set DEBIAN_FRONTEND=noninteractive to suppress prompts.
Check user/group, sudo access, Docker availability, apt-get access, and Playwright status to determine what the agent can actually do.
The default Linux queue has Docker but no apt-get or sudo, so Playwright's system dependencies (libatk, etc.) cannot be installed on the host. Run the tests inside the official Playwright Docker image which has all system deps pre-installed, using --network host so the container can reach wp-env on localhost:8888 and the Vite preview server on localhost:4173.
The default queue has DOCKER_USERNS_REMAP enabled, which prevents --network host. Adding --userns=host disables user namespace remapping for this container so host networking works.
Verify Gutenberg plugin installation, check REST API route registration, and test the editor settings endpoint directly before running E2E tests.
The /wp-json/ pretty permalink returns HTML instead of JSON, suggesting rewrite rules aren't working. Test both pretty permalink and ?rest_route= query param approaches, and verify the auth header is being captured correctly.
wp rewrite structure --hard warns that it cannot generate a .htaccess file inside the wp-env Docker container, leaving Apache without rewrite rules. This causes /wp-json/ requests to 404. Write the standard WordPress .htaccess directly into the container via wp-env run, including the HTTP_AUTHORIZATION passthrough rule so application password auth works through Apache. Also remove CI diagnostic commands now that the root cause is identified.
The wordpress container's shell user cannot write to /var/www/html/. Use wp eval to write the file from PHP via WP-CLI, which runs with the correct filesystem permissions.
Both wp-env run wordpress and wp-env run cli lack write permissions to /var/www/html/. Use docker exec -u 0 (root) on the WordPress container to write the .htaccess file directly.
wp-env builds a custom Docker image, so filtering by ancestor=wordpress doesn't match. Filter by publish=8888 instead, which matches the wp-env development site port. Also add diagnostic output on failure.
Log all requests, responses, and failures to localhost:8888 during the image upload test to diagnose why media uploads time out in CI. Captures HTTP method, URL, relevant headers (origin, authorization, content-type, CORS headers), and failure reasons.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What?
Why?
How?
Testing Instructions
Accessibility Testing Instructions
Screenshots or screencast