mirror of
https://github.com/go-vikunja/vikunja.git
synced 2026-04-24 22:25:15 +00:00
feat(ci): build frontend before test
This commit is contained in:
28
.github/workflows/test.yml
vendored
28
.github/workflows/test.yml
vendored
@@ -262,11 +262,26 @@ jobs:
|
||||
- name: Run unit tests
|
||||
working-directory: frontend
|
||||
run: pnpm test:unit
|
||||
|
||||
|
||||
build-frontend:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
- uses: ./.github/actions/setup-frontend
|
||||
- name: Build frontend
|
||||
working-directory: frontend
|
||||
run: pnpm build
|
||||
- name: Store Frontend
|
||||
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
|
||||
with:
|
||||
name: frontend_dist
|
||||
path: ./frontend/dist
|
||||
|
||||
test-frontend-e2e:
|
||||
runs-on: ubuntu-latest
|
||||
needs:
|
||||
- api-build
|
||||
- build-frontend
|
||||
strategy:
|
||||
# when one test fails, DO NOT cancel the other
|
||||
# containers, because this will kill Cypress processes
|
||||
@@ -277,15 +292,16 @@ jobs:
|
||||
containers: [1, 2, 3, 4, 5]
|
||||
steps:
|
||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
- uses: ./.github/actions/setup-frontend
|
||||
- name: Download Vikunja Binary
|
||||
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4
|
||||
with:
|
||||
name: vikunja_bin
|
||||
- name: Build frontend for test
|
||||
run: |
|
||||
cd frontend
|
||||
pnpm build
|
||||
- uses: ./.github/actions/setup-frontend
|
||||
- name: Download Frontend
|
||||
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4
|
||||
with:
|
||||
name: frontend_dist
|
||||
path: ./frontend/dist
|
||||
- name: Run api
|
||||
env:
|
||||
VIKUNJA_SERVICE_TESTINGTOKEN: averyLongSecretToSe33dtheDB
|
||||
|
||||
Reference in New Issue
Block a user