browser-extension
browser-extension copied to clipboard
refactor: e2e script cleanup
What changed
- Created a unified E2E test runner script (
e2e.sh) that replaces multiple separate scripts - Added support for headless/headed browser testing with
HEADLESS_MODEenvironment variable (on by default) - Updated all E2E test commands in package.json to use the new unified script
- Improved test path handling to allow running specific test files or directories
- Updated GitHub workflows to use the new E2E commands
- Enhanced documentation in README.md and CLAUDE.md with clearer E2E test instructions
- Added better chain configuration handling for different test environments
What to test
- Run E2E tests with the new commands:
-
yarn e2e- runs all tests in headless mode -
yarn e2e:headed- runs tests with visible browser -
yarn e2e serial/send/1_sendFlow.test.ts- runs a specific test file -
yarn e2e ./e2e/parallel/- runs all tests in a directory
-
- Verify that the specialized test commands still work:
-
yarn e2e:parallel -
yarn e2e:swap -
yarn e2e:send -
yarn e2e:send:optimism -
yarn e2e:dappInteractions
-
- Check that the GitHub workflows execute correctly with the updated commands
PR-Codex overview
This PR focuses on restructuring end-to-end (E2E) testing scripts, enhancing the functionality and clarity of E2E tests while removing outdated scripts.
Detailed summary
- Deleted legacy E2E test scripts:
scripts/e2e-serial-tests.sh,scripts/e2e-parallel-tests.sh,scripts/e2e-op-serial-tests.sh. - Updated
README.mdto reflect new E2E test commands and options. - Modified
.github/workflows/claude-review.ymlto adjust disallowed tools. - Enhanced
e2e/helpers.tsto support headless mode for Firefox and Chrome. - Updated
package.jsonto replace old scripts with a unified./scripts/e2e.shscript for E2E tests. - Added a new
scripts/e2e.shscript that consolidates E2E test execution with options for parallel and serial tests. - Adjusted
.github/workflows/build.ymlto use new E2E commands instead of deprecatedvitestcommands.
✨ Ask PR-Codex anything about this PR by commenting with
/codex {your question}
-
#2012
👈 (View in Graphite)
-
master
This stack of pull requests is managed by Graphite. Learn more about stacking.