diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml new file mode 100644 index 0000000..36e0cb7 --- /dev/null +++ b/.github/workflows/test.yaml @@ -0,0 +1,42 @@ +name: Test + +on: + push: + branches: ['main'] + pull_request: + branches: ['main'] + +permissions: + contents: read + +jobs: + test: + runs-on: ubuntu-latest + container: + image: cimg/node:18.17.1 + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install packages + run: npm ci + + - name: Lint + run: npm run lint + + - name: Run unit tests + run: npm t + + - name: Build + run: npm run build + + - name: Upload Build Artifacts + uses: actions/upload-artifact@v2 + with: + name: build-artifacts + path: | + dist + prisma + Dockerfile + .dockerignore + package*.json