ci.yml 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. name: CI
  2. on:
  3. push:
  4. branches: [master]
  5. pull_request:
  6. branches: [master]
  7. jobs:
  8. lint:
  9. name: Linting Checks
  10. runs-on: ubuntu-latest
  11. steps:
  12. - name: Checkout
  13. uses: actions/checkout@v1
  14. - name: Setup NodeJs
  15. uses: actions/setup-node@v2
  16. with:
  17. node-version: "lts/*"
  18. - name: Install Dependencies
  19. run: yarn install --frozen-lockfile
  20. - name: Run Linting Checks
  21. run: yarn lint
  22. test:
  23. name: "Test - Node: ${{ matrix.node_version }} - OS: ${{ matrix.os }}"
  24. runs-on: ubuntu-latest
  25. strategy:
  26. fail-fast: true
  27. matrix:
  28. os:
  29. - "ubuntu-latest"
  30. node_version:
  31. - "12"
  32. - "14"
  33. - "16"
  34. steps:
  35. - uses: actions/checkout@v1
  36. - name: Use Node.js ${{ matrix.node-version }}
  37. uses: actions/setup-node@v1
  38. with:
  39. node-version: ${{ matrix.node-version }}
  40. - name: yarn install
  41. run: yarn install --frozen-lockfile
  42. - name: build
  43. run: yarn build
  44. - name: test
  45. run: yarn test-coverage
  46. - name: Report coverage
  47. uses: codecov/codecov-action@v1
  48. with:
  49. file: coverage/lcov.info