Skip to content

feat: update status page link (#3381) #1994

feat: update status page link (#3381)

feat: update status page link (#3381) #1994

Workflow file for this run

name: Run tests
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
jobs:
generate-matrix-with-packages:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.generate-matrix.outputs.matrix }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 20.x
- id: generate-matrix
run: |
RESULT=$(node .github/workflows/scripts/get-all-packages-by-name.js)
echo "matrix=$RESULT" >> $GITHUB_OUTPUT
test:
timeout-minutes: 30
runs-on: ubuntu-latest
needs: generate-matrix-with-packages
permissions:
contents: read
strategy:
matrix:
node-version: [20.x, 22.x]
package: ${{fromJson(needs.generate-matrix-with-packages.outputs.matrix)}}
fail-fast: false
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm run build
- run: npm run test --workspace ${{ matrix.package }}
env:
FORCE_COLOR: 1
- name: Notify about failures
if: failure() && github.ref == 'refs/heads/main'
uses: 8398a7/[email protected]
with:
status: ${{ job.status }}
fields: repo,message,commit,author,eventName,job,took,pullRequest
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
test-windows:
timeout-minutes: 60
runs-on: windows-latest
needs: generate-matrix-with-packages
continue-on-error: true
permissions:
contents: read
id-token: write
steps:
- uses: actions/checkout@v3
- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x
- run: npm install
- run: npm run build
- name: Run windows tests and capture exit code
continue-on-error: true
run: |
npm run test:windows --workspace artillery
echo "HAS_PASSED=$?" >> $env:GITHUB_ENV
env:
FORCE_COLOR: 1
- name: Notify about failures
if: env.HAS_PASSED == 'False'
uses: 8398a7/[email protected]
with:
status: failure
fields: repo,message,commit,author,eventName,job,took,pullRequest
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}