Skip to content

Commit

Permalink
- Updated workflow to include tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Franck Cornu committed Nov 27, 2023
1 parent 35324c0 commit 048f09d
Showing 1 changed file with 33 additions and 1 deletion.
34 changes: 33 additions & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,42 @@ jobs:
echo "majorMinorPatch=$GITVERSION_MAJORMINORPATCH" >> "$GITHUB_OUTPUT"
echo "semver=$GITVERSION_SEMVER" >> "$GITHUB_OUTPUT"
tests:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0

- uses: pnpm/action-setup@v2
with:
version: 8
run_install: false

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
run: pnpm install

- name: Tests
run: pnpm run test

publish:

runs-on: ubuntu-latest
needs: version
needs: [version, tests]
defaults:
run:
working-directory: ./packages/components
Expand Down

0 comments on commit 048f09d

Please sign in to comment.