Skip to content

Commit

Permalink
ci(cypress): Build app in init step
Browse files Browse the repository at this point in the history
Signed-off-by: Jonas <jonas@freesources.org>
  • Loading branch information
mejo- committed Sep 4, 2023
1 parent bcd02cc commit 8cdbc41
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions .github/workflows/cypress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ jobs:
with:
fallbackNode: '^20'
fallbackNpm: '^9'
path: apps/${{ env.APP_NAME }}

- name: Set up node ${{ steps.versions.outputs.nodeVersion }}
uses: actions/setup-node@e33196f7422957bea03ed53f6fbb155025ffc7b8 # v3
Expand All @@ -109,6 +110,12 @@ jobs:
- name: Set up npm ${{ steps.versions.outputs.npmVersion }}
run: npm i -g npm@"${{ steps.versions.outputs.npmVersion }}"

- name: Install dependencies & build
working-directory: apps/${{ env.APP_NAME }}
run: |
npm ci
npm run build --if-present
- name: Save context
uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
Expand Down Expand Up @@ -160,12 +167,6 @@ jobs:
working-directory: apps/${{ env.APP_NAME }}
run: composer i --no-dev

- name: Install dependencies & build
working-directory: apps/${{ env.APP_NAME }}
run: |
npm ci
npm run build --if-present
- name: Set up Nextcloud
env:
DB_PORT: 4444
Expand All @@ -192,7 +193,7 @@ jobs:
- name: Run Nextcloud
run: php -S 0.0.0.0:8081 &

- name: Run Cypress
- name: Cypress run
uses: cypress-io/github-action@v5
with:
record: true
Expand Down

0 comments on commit 8cdbc41

Please sign in to comment.