-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow E2E testing with Release Candidates #2043
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @mikkamp, thanks for adding an easy way to test with RCs.
Tested the branch locally and getting environments with specific versions set up and running tests against them is easy and works well.
Although not related directly to the changes here (I think) I am getting a test failure.
It looks like the endpoint being called isn't available as the test-data.php
plugin gets deactivated due to an invalid header.
All others tests are passing though and no issues settings release candidates so LGTM ✅
Interesting error, I'm not able to replicate that and it's the first time I come across it. From a quick search on Google I see mentions of this happening when the plugin is activated too quick after installing, activating it a second time usually works. Do you still get that error after trying again? One thing we could try is add a mapping in wp-env and then activate it in the install script (which is what WC does with a custom plugin). Should I add a commit for that change, or is that something you can test locally (since I'm not getting the same error here)? |
Changes proposed in this Pull Request:
As a followup to PR #2041 this PR makes it easier to install Release Candidate versions of both WordPress and WooCommerce. The documentation has been updated to describe how the tests can be run with different versions of WordPress and WooCommerce.
Additionally several selectors in the test were updated as WooCommerce 8.0 introduces blocks for the standard checkout.
I also added workflow inputs to allow the E2E workflow to be run with release candidate versions of WP and/or WC. I ran the test successfully here with WP
6.3-RC3
and WC8.0.0-rc.1
.Detailed test instructions:
nvm use && npm ci
wp-env
environment:npm run wp-env:up
(if you previously had this running you might need to runnpm run wp-env destroy
)npx playwright install chromium
npm run test:e2e
Changelog entry