checks.yml 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. name: checks
  2. on:
  3. push:
  4. branches:
  5. - master
  6. - release-v*
  7. pull_request: {}
  8. workflow_dispatch: {}
  9. concurrency:
  10. group: checks-${{ github.ref }}
  11. cancel-in-progress: true
  12. jobs:
  13. lint:
  14. if: github.repository != 'OpenZeppelin/openzeppelin-contracts-upgradeable'
  15. runs-on: ubuntu-latest
  16. steps:
  17. - uses: actions/checkout@v3
  18. - name: Set up environment
  19. uses: ./.github/actions/setup
  20. - run: npm run lint
  21. tests:
  22. runs-on: ubuntu-latest
  23. env:
  24. FORCE_COLOR: 1
  25. GAS: true
  26. steps:
  27. - uses: actions/checkout@v3
  28. - name: Set up environment
  29. uses: ./.github/actions/setup
  30. - name: Run tests and generate gas report
  31. run: npm run test
  32. - name: Check linearisation of the inheritance graph
  33. run: npm run test:inheritance
  34. - name: Check proceduraly generated contracts are up-to-date
  35. if: github.repository != 'OpenZeppelin/openzeppelin-contracts-upgradeable'
  36. run: npm run test:generation
  37. - name: Compare gas costs
  38. uses: ./.github/actions/gas-compare
  39. with:
  40. token: ${{ github.token }}
  41. coverage:
  42. if: github.repository != 'OpenZeppelin/openzeppelin-contracts-upgradeable'
  43. runs-on: ubuntu-latest
  44. steps:
  45. - uses: actions/checkout@v3
  46. - name: Set up environment
  47. uses: ./.github/actions/setup
  48. - run: npm run coverage
  49. env:
  50. NODE_OPTIONS: --max_old_space_size=4096
  51. - uses: codecov/codecov-action@v3
  52. slither:
  53. if: github.repository != 'OpenZeppelin/openzeppelin-contracts-upgradeable'
  54. runs-on: ubuntu-latest
  55. steps:
  56. - uses: actions/checkout@v3
  57. - name: Set up environment
  58. uses: ./.github/actions/setup
  59. - uses: crytic/slither-action@v0.1.1