Skip to content

Commit

Permalink
ci: upload all cy artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
floydnant committed Nov 17, 2023
1 parent cfbd459 commit c24491d
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 7 deletions.
20 changes: 13 additions & 7 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ jobs:
cache: 'npm'
cache-dependency-path: client-v2/package-lock.json

- run: cd client-v2
- run: npm ci
working-directory: ./client-v2

Expand All @@ -35,6 +34,14 @@ jobs:
- run: npm run comp:ci
working-directory: ./client-v2

- name: Upload component test artifacts
uses: actions/upload-artifact@v3
if: always()
with:
name: component test artifacts
path: client-v2/.cypress/component
retention-days: 7

# - name: Upload coverage artifacts
# uses: actions/upload-artifact@v3
# with:
Expand All @@ -60,11 +67,10 @@ jobs:
cache: 'npm'
cache-dependency-path: server/package-lock.json

- run: cd server
- run: npm ci
working-directory: ./server

- run: npm run build --if-present
- run: npm run build
working-directory: ./server

- run: npm run lint
Expand All @@ -73,7 +79,7 @@ jobs:
- run: npm run typecheck-snapshot-scripts
working-directory: ./server

- name: Setup Postgres
- name: Setup Postgres
uses: Daniel-Marynicz/postgresql-action@master
with:
postgres_image_tag: 12-alpine
Expand Down Expand Up @@ -131,10 +137,10 @@ jobs:
- run: npm run e2e:ci
working-directory: ./client-v2

- name: Upload e2e test videos
- name: Upload e2e test artifacts
uses: actions/upload-artifact@v3
if: always()
with:
name: e2e test videos
path: client-v2/cypress/videos
name: e2e test artifacts
path: client-v2/.cypress/e2e
retention-days: 7
8 changes: 8 additions & 0 deletions client-v2/cypress.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,11 @@ export default defineConfig({
e2e: {
baseUrl: 'http://localhost:4200',
supportFile: './cypress/support/e2e.ts',

video: true,
videosFolder: './.cypress/e2e/videos',
screenshotsFolder: './.cypress/e2e/screenshots',
downloadsFolder: './.cypress/e2e/downloads',
},

component: {
Expand All @@ -13,6 +17,10 @@ export default defineConfig({
bundler: 'webpack',
},
specPattern: '**/*.test.ts',

video: true,
videosFolder: './.cypress/component/videos',
screenshotsFolder: './.cypress/component/screenshots',
downloadsFolder: './.cypress/component/downloads',
},
})

0 comments on commit c24491d

Please sign in to comment.