-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #167 from tjheffner/playwright
Initial Playwright tests + style updates
- Loading branch information
Showing
20 changed files
with
1,121 additions
and
165 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
name: Playwright Tests | ||
|
||
on: [pull_request] | ||
|
||
env: | ||
GITHUB_PR_NUMBER: ${{github.event.pull_request.number}} | ||
|
||
jobs: | ||
prepare: | ||
name: Wait for Netlify deployment | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Waiting for Netlify Preview | ||
uses: jakepartusch/[email protected] | ||
id: wait-for-netlify-preview | ||
with: | ||
site_name: "heffner" | ||
max_timeout: 180 | ||
|
||
test: | ||
needs: prepare | ||
name: Run tests against PR environment | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 5 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-node@v4 | ||
- name: install dependencies | ||
run: npm ci | ||
- name: install playwright browsers | ||
run: npx playwright install --with-deps | ||
- name: run tests | ||
run: npm run test | ||
env: | ||
PLAYWRIGHT_TEST_BASE_URL: "https://deploy-preview-${{env.GITHUB_PR_NUMBER}}--heffner.netlify.app/" | ||
- uses: actions/upload-artifact@v4 | ||
if: always() | ||
with: | ||
name: playwright-report | ||
path: playwright-report/ | ||
retention-days: 30 |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,3 +9,7 @@ node_modules | |
|
||
# Local Netlify folder | ||
.netlify | ||
/test-results/ | ||
/playwright-report/ | ||
/blob-report/ | ||
/playwright/.cache/ |
This file contains 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
Oops, something went wrong.