Skip to content

Commit

Permalink
Add GitHub Actions workflow for testing API package
Browse files Browse the repository at this point in the history
  • Loading branch information
martdo02 committed Jan 24, 2024
1 parent fde25e0 commit 037464a
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/package-api.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Test API Package

on:
push:
branches: [ main ]
paths:
- 'packages/api/**'
pull_request:
paths:
- 'packages/api/**'

jobs:
MAF-API:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.x, 20.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/previous-releases

steps:
- uses: actions/[email protected]

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}

- run: npm ci

- run: npm test -w packages/api
env:
ENVIRONMENT: CI

- name: Status Create Action
if: ${{ always() }}
uses: hkusu/[email protected]
id: status-create
with:
state: ${{ job.status }}
sha: ${{ github.sha }}

- name: Show result
if: always()
run: echo '${{ steps.status-create.outputs.result }}'

0 comments on commit 037464a

Please sign in to comment.