From 2c038a88e2aa804c8e1a2484740d7f16624ce055 Mon Sep 17 00:00:00 2001 From: John Whitlock Date: Tue, 16 Apr 2024 13:33:21 -0500 Subject: [PATCH 1/2] Add instructions for testing playright updates --- docs/dependency-updates.md | 40 ++++++++++++++++++++++++++------------ 1 file changed, 28 insertions(+), 12 deletions(-) diff --git a/docs/dependency-updates.md b/docs/dependency-updates.md index ce18049e47..694e4153b3 100644 --- a/docs/dependency-updates.md +++ b/docs/dependency-updates.md @@ -60,18 +60,34 @@ see code coverage for the frontend. ### `@playwright/test` and `dotenv` -Our Playwright tests are currently only triggered in CI once a day from the -`main` branch. Thus, there's unfortunately no easy way to verify that it still -runs successfully until after merging. To do so, after merging the PR, open the -"Actions" tab in GitHub, then find the "[Relay e2e -Tests](https://github.com/mozilla/fx-private-relay/actions/workflows/playwright.yml)" -workflow on the left-hand side, and then use the "Run workflow" trigger button -in the top row of the table. Alternatively, you can also try run the end-to-end -tests locally by following the instructions in -[../e2e-tests/README.md](../e2e-tests/README.md#how-to-run). - -`dotenv` is used to load environment variables for Playwright from `.env` files, -so can be verified in the same way. +Our Playwright tests run as a GitHub action [Relay e2e Tests][] once a day from +the `main` branch. See [../e2e-tests/README.md](../e2e-tests/README.md#how-to-run) +for instructions on running the tests locally. + +To test updates to `@playwright/test` and `dotenv`, add the following to the +`.env` file: + +``` +E2E_TEST_ACCOUNT_PASSWORD= +E2E_TEST_ENV=stage +``` + +Check out the update branch and run: + +``` +npm install +npx playwright install +npx playwright test +``` + +This will confirm that `dotenv` picked up the settings from `.env`, and that +the new playwright runs against stage. + +Once the PR is merged, you can wait for the daily test run, or manually run the +test by going to the [Relay e2e Tests][] GitHub Action page, select "Run +workflow", and pick the `main` branch and the `stage` environment. + +[Relay e2e Tests]: https://github.com/mozilla/fx-private-relay/actions/workflows/playwright.yml ### `react-aria` and `react-stately` From cbc757a2edd62f1cc647e3bec02ce458cb6f41d1 Mon Sep 17 00:00:00 2001 From: John Whitlock Date: Thu, 18 Apr 2024 08:06:04 -0500 Subject: [PATCH 2/2] Fix spelling s/randon/random/ Co-authored-by: Rafee Rahman <59676643+rafeerahman@users.noreply.github.com> --- docs/dependency-updates.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/dependency-updates.md b/docs/dependency-updates.md index 694e4153b3..af11f72c15 100644 --- a/docs/dependency-updates.md +++ b/docs/dependency-updates.md @@ -68,7 +68,7 @@ To test updates to `@playwright/test` and `dotenv`, add the following to the `.env` file: ``` -E2E_TEST_ACCOUNT_PASSWORD= +E2E_TEST_ACCOUNT_PASSWORD= E2E_TEST_ENV=stage ```