test.yaml 868 B

123456789101112131415161718192021222324252627282930
  1. name: test
  2. on: [ push, pull_request ]
  3. jobs:
  4. test:
  5. runs-on: ubuntu-latest
  6. steps:
  7. - name: Checkout code
  8. uses: actions/checkout@v3
  9. - name: Install Go
  10. uses: actions/setup-go@v4
  11. with:
  12. go-version: '1.22.x'
  13. - name: Install node
  14. uses: actions/setup-node@v3
  15. with:
  16. node-version: '20'
  17. cache: 'npm'
  18. cache-dependency-path: './web/package-lock.json'
  19. - name: Install dependencies
  20. run: make build-deps-ubuntu
  21. - name: Build docs (required for tests)
  22. run: make docs
  23. - name: Build web app (required for tests)
  24. run: make web
  25. - name: Run tests, formatting, vetting and linting
  26. run: make check
  27. - name: Run coverage
  28. run: make coverage
  29. - name: Upload coverage to codecov.io
  30. run: make coverage-upload