add test to github action

This commit is contained in:
Amruth Pillai 2024-05-05 17:06:08 +02:00
parent 8180e8c7b8
commit 7a65363296
No known key found for this signature in database

View File

@ -1,13 +1,13 @@
name: Lint and Build name: Lint, Test and Build
on: on:
workflow_dispatch:
push: push:
branches: branches:
- main - main
pull_request: pull_request:
branches: branches:
- main - main
workflow_dispatch:
permissions: permissions:
actions: read actions: read
@ -30,16 +30,14 @@ jobs:
number-of-agents: 1 number-of-agents: 1
init-commands: | init-commands: |
pnpm exec prisma generate pnpm exec prisma generate
pnpm exec nx-cloud start-ci-run --stop-agents-after="build" --agent-count=3 pnpm exec nx-cloud start-ci-run --stop-agents-after="build" --agent-count=1
parallel-commands: |
pnpm exec nx-cloud record -- pnpm exec nx format:check
parallel-commands-on-agents: | parallel-commands-on-agents: |
pnpm exec nx affected --target=lint pnpm exec nx-cloud record -- pnpm exec nx affected --target=lint
pnpm exec nx affected --target=test pnpm exec nx-cloud record -- pnpm exec nx affected --target=test
pnpm exec nx affected --target=build pnpm exec nx-cloud record -- pnpm exec nx affected --target=build
agents: agents:
name: Nx Cloud - Agents name: Nx Cloud - Agents
uses: nrwl/ci/.github/workflows/nx-cloud-agents.yml@v0.14.0 uses: nrwl/ci/.github/workflows/nx-cloud-agents.yml@v0.14.0
with: with:
number-of-agents: 3 number-of-agents: 1