From 292e88ba50525cabb54cf7344544f836a79077e3 Mon Sep 17 00:00:00 2001 From: Ethan Gardner Date: Mon, 1 Jul 2024 12:44:10 -0400 Subject: [PATCH] debugging issue on main (#235) * debugging issue on main with end-to-end tests --- .github/workflows/_playwright.yml | 6 ++---- .github/workflows/deploy.yml | 3 +-- documents/adr/0010-end-to-end-testing.md | 18 ++++++++++++++++++ 3 files changed, 21 insertions(+), 6 deletions(-) create mode 100644 documents/adr/0010-end-to-end-testing.md diff --git a/.github/workflows/_playwright.yml b/.github/workflows/_playwright.yml index 41176812..5729e768 100644 --- a/.github/workflows/_playwright.yml +++ b/.github/workflows/_playwright.yml @@ -1,9 +1,7 @@ name: Playwright Tests on: -# push: -# branches: [ main, master ] - pull_request: - branches: [ main, master ] + workflow_call: + jobs: end_to_end: timeout-minutes: 60 diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 064acbc5..4a228694 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -28,8 +28,7 @@ jobs: secrets: inherit with: deploy-env: ${{ github.ref_name }} - e2e: needs: [deploy] uses: ./.github/workflows/_playwright.yml - secrets: inherit + secrets: inherit \ No newline at end of file diff --git a/documents/adr/0010-end-to-end-testing.md b/documents/adr/0010-end-to-end-testing.md new file mode 100644 index 00000000..c7f5c9aa --- /dev/null +++ b/documents/adr/0010-end-to-end-testing.md @@ -0,0 +1,18 @@ +# 10. End to end testing + +Date: 2024-07-01 + +## Status + +Pending + +## Context + +Certain tests are not able to be performed with Storybook and JSDOM (e.g. drag-and-drop). The ability to replicate more complex user interactions in the test suite through an actual browser can provide this feature. + +## Decision +The end-to-end tests should be used sparingly since they are slower to run than the ones through JSDOM. Storybook still should be the primary mechanism for testing, and the Playwright tests will round out what isn't possible there. + +## Consequences + +The deployed application will include Playwright tests in the e2e package.