Skip to content

Commit

Permalink
chore(ci): persist cache directory on CI failures
Browse files Browse the repository at this point in the history
  • Loading branch information
dirkdev98 committed Sep 15, 2023
1 parent 9ee0036 commit b74d1fe
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/main-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,14 @@ jobs:
npx zakmes
npx compas test
- name: Persist debug artifacts
uses: actions/upload-artifact@v3
if: failure()
with:
name:
cache-artifact-test-${{ matrix.node }}-${{ matrix.postgresVersion }}
path: .cache/

coverage:
permissions:
contents: read
Expand Down Expand Up @@ -104,6 +112,15 @@ jobs:
run: |
npx compas test --coverage
- name: Persist debug artifacts
uses: actions/upload-artifact@v3
if: failure()
with:
name:
cache-artifact-coverage-${{ matrix.node }}-${{
matrix.postgresVersion }}
path: .cache/

- name: Upload coverage
if: matrix.node == '18'
uses: codecov/codecov-action@v3
Expand Down
17 changes: 17 additions & 0 deletions .github/workflows/pr-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,14 @@ jobs:
npx zakmes
npx compas test
- name: Persist debug artifacts
uses: actions/upload-artifact@v3
if: failure()
with:
name:
cache-artifact-test-${{ matrix.node }}-${{ matrix.postgresVersion }}
path: .cache/

coverage:
permissions:
contents: read
Expand Down Expand Up @@ -134,6 +142,15 @@ jobs:
run: |
npx compas test --coverage
- name: Persist debug artifacts
uses: actions/upload-artifact@v3
if: failure()
with:
name:
cache-artifact-coverage-${{ matrix.node }}-${{
matrix.postgresVersion }}
path: .cache/

- name: Upload coverage
uses: codecov/codecov-action@v3
with:
Expand Down

0 comments on commit b74d1fe

Please sign in to comment.