Fix: failure type is now optional (#32) #125
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: | |
| - '*' | |
| pull_request: | |
| branches: | |
| - main | |
| - dev | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v3 | |
| - name: Use Node.js 20 | |
| uses: actions/setup-node@v3 | |
| with: | |
| node-version: 20 | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm install | |
| - name: Run linter | |
| run: npm run lint | |
| - name: Run tests | |
| run: npm test | |
| - name: Build project | |
| run: npm run build | |
| - name: CLI smoke test | |
| run: node ./build/bin/qasphere.js --help | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Cache Docker images | |
| uses: actions/cache@v3 | |
| with: | |
| path: /tmp/.buildx-cache | |
| key: ${{ runner.os }}-docker-${{ hashFiles('mnode-test/docker-test.sh') }} | |
| restore-keys: | | |
| ${{ runner.os }}-docker- | |
| - name: Pre-pull Docker images | |
| run: | | |
| echo "Pre-pulling Node.js Docker images..." | |
| docker pull node:18-alpine || true | |
| docker pull node:20-alpine || true | |
| docker pull node:22-alpine || true | |
| docker pull node:24-alpine || true | |
| - name: Multi-node version test | |
| run: cd mnode-test && ./docker-test.sh |