ci: add matrix status job (#83)
This commit is contained in:
parent
6523e70eaf
commit
4607817057
|
@ -1,31 +1,46 @@
|
||||||
name: CI
|
name: CI
|
||||||
|
|
||||||
on: [push, pull_request]
|
on: [push, pull_request, workflow_dispatch]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
test:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 30
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
nim: [1.6.20, stable]
|
nim: [1.6.20, stable]
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Install Nim
|
- name: Install Nim
|
||||||
uses: iffy/install-nim@v3
|
uses: iffy/install-nim@v4
|
||||||
with:
|
with:
|
||||||
version: ${{ matrix.nim }}
|
version: ${{ matrix.nim }}
|
||||||
|
|
||||||
- name: Install NodeJS
|
- name: Install NodeJS
|
||||||
uses: actions/setup-node@v2
|
uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version: '18'
|
node-version: 18
|
||||||
|
|
||||||
- name: Install test node
|
- name: Install test node
|
||||||
working-directory: testnode
|
working-directory: testnode
|
||||||
run: npm install
|
run: npm install
|
||||||
|
|
||||||
- name: Run test node
|
- name: Run test node
|
||||||
working-directory: testnode
|
working-directory: testnode
|
||||||
run: npm start &
|
run: npm start &
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: nimble install -y
|
run: nimble install -y
|
||||||
|
|
||||||
- name: Test
|
- name: Test
|
||||||
run: nimble test -y
|
run: nimble test -y
|
||||||
|
|
||||||
|
status:
|
||||||
|
if: always()
|
||||||
|
needs: [test]
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') || contains(needs.*.result, 'skipped') }}
|
||||||
|
run: exit 1
|
||||||
|
|
Loading…
Reference in New Issue