54 lines
1.0 KiB
YAML
Raw Normal View History

2022-01-26 14:41:22 +01:00
name: CI
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
2022-01-26 14:41:22 +01:00
jobs:
test:
runs-on: ubuntu-latest
2024-10-28 15:27:50 +02:00
timeout-minutes: 30
2022-01-26 14:41:22 +01:00
strategy:
matrix:
nim: [1.6.20, stable]
2022-01-26 14:41:22 +01:00
steps:
- name: Checkout
2024-10-28 15:27:50 +02:00
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
2024-10-28 15:27:50 +02:00
2022-01-26 14:41:22 +01:00
- name: Install Nim
2024-10-28 15:27:50 +02:00
uses: iffy/install-nim@v4
2022-01-26 14:41:22 +01:00
with:
version: ${{ matrix.nim }}
2024-10-28 15:27:50 +02:00
2022-01-26 14:41:22 +01:00
- name: Install NodeJS
2024-10-28 15:27:50 +02:00
uses: actions/setup-node@v4
2022-01-26 14:41:22 +01:00
with:
2024-10-28 15:27:50 +02:00
node-version: 18
2022-01-26 14:41:22 +01:00
- name: Install test node
working-directory: testnode
run: npm install
2024-10-28 15:27:50 +02:00
2022-01-26 14:41:22 +01:00
- name: Run test node
2022-01-27 10:07:52 +01:00
working-directory: testnode
2022-01-26 14:41:22 +01:00
run: npm start &
2024-10-28 15:27:50 +02:00
2022-01-26 14:41:22 +01:00
- name: Build
run: nimble install -y
2024-10-28 15:27:50 +02:00
2022-01-26 14:41:22 +01:00
- name: Test
run: nimble test -y
2024-10-28 15:27:50 +02:00
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