Skip to content

Commit a4be691

Browse files
committed
ci: Add workflow for running unit tests
Signed-off-by: David van der Spek <vanderspek.david@gmail.com>
1 parent 097e5b5 commit a4be691

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

.github/workflows/ci.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,24 @@ jobs:
2424
- run: |
2525
yarn install --immutable
2626
- run: yarn build
27+
test:
28+
name: Unit test
29+
runs-on: ubuntu-20.04
30+
defaults:
31+
run:
32+
shell: bash
33+
working-directory: assets
34+
steps:
35+
- name: 'Checkout'
36+
uses: actions/checkout@v3
37+
- name: Read Node.js version from package.json
38+
run: echo "nodeVersion=$(node -p "require('./package.json').engines.node")" >> $GITHUB_OUTPUT
39+
id: engines
40+
- uses: actions/setup-node@v3
41+
with:
42+
node-version: ${{ steps.engines.outputs.nodeVersion }}
43+
- run: yarn --immutable
44+
- run: yarn test
2745
build-storybook:
2846
name: Build Storybook
2947
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)