tests.yml 708 B

12345678910111213141516171819202122232425262728293031323334353637
  1. name: Node.js CI
  2. on:
  3. push:
  4. branches: [main]
  5. pull_request:
  6. branches: [main]
  7. jobs:
  8. build:
  9. runs-on: ubuntu-latest
  10. strategy:
  11. matrix:
  12. node-version: ["lts/*"]
  13. steps:
  14. - name: Checkout Repository
  15. uses: actions/checkout@v3
  16. - name: Setup Environment
  17. run: mv .env.example .env
  18. - name: Setup and run pnpm install
  19. uses: pnpm/action-setup@v2.2.4
  20. with:
  21. version: 7
  22. run_install: true
  23. - name: Use Node.js ${{ matrix.node-version }}
  24. uses: actions/setup-node@v3
  25. with:
  26. node-version: ${{ matrix.node-version }}
  27. cache: pnpm
  28. - name: Run tests
  29. run: pnpm test