:electron: Playwright testing for electron (#4674)

* playwright testing for electron

* pipeline updates

* fix normal e2e scripts

* fix path to artifact

* listing out whats there

* attempt to fix ci

* umm

* again

* setting a viewport

* window size to be consistent across machine for tests

* now it work... Righhttt?

* hmm

* do it

* worflow

* will this work

* oops

* dont skip

* trust in the pipeline gods

* remove update snapshots, just do it in the pipeline

* change name of snapshot to account for os

* lint

* fix package script
This commit is contained in:
Michael Clark
2025-04-05 09:19:06 +01:00
committed by GitHub
parent 82b6589c37
commit 26ee3179e1
15 changed files with 130 additions and 32 deletions

View File

@@ -48,6 +48,27 @@ jobs:
path: packages/desktop-client/test-results/
retention-days: 30
overwrite: true
functional-desktop-app:
name: Functional Desktop App
runs-on: ubuntu-latest
container:
image: mcr.microsoft.com/playwright:v1.41.1-jammy
steps:
- uses: actions/checkout@v4
- name: Set up environment
uses: ./.github/actions/setup
- name: Run Desktop app E2E Tests
run: |
xvfb-run --auto-servernum --server-args="-screen 0 1920x1080x24" -- yarn e2e:desktop
- uses: actions/upload-artifact@v4
if: always()
with:
name: desktop-app-test-results
path: packages/desktop-electron/e2e/test-results/
retention-days: 30
overwrite: true
vrt:
name: Visual regression
needs: netlify

View File

@@ -1,7 +1,7 @@
name: /update-vrt
on:
issue_comment:
types: [ created ]
types: [created]
permissions:
pull-requests: read
@@ -22,7 +22,7 @@ jobs:
image: mcr.microsoft.com/playwright:v1.41.1-jammy
steps:
- name: Get PR branch
# Until https://github.com/xt0rted/pull-request-comment-branch/issues/322 is resolved we use the forked version
# Until https://github.com/xt0rted/pull-request-comment-branch/issues/322 is resolved we use the forked version
uses: gotson/pull-request-comment-branch@head-repo-owner-dist
id: comment-branch
- uses: actions/checkout@v4
@@ -97,7 +97,7 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
commentId: ${{ github.event.comment.id }}
reaction: "rocket"
reaction: 'rocket'
add-starting-reaction:
runs-on: ubuntu-latest
@@ -112,4 +112,4 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
commentId: ${{ github.event.comment.id }}
reaction: "+1"
reaction: '+1'