ci.yml 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. name: CI
  2. on:
  3. pull_request:
  4. paths-ignore:
  5. - 'build/**'
  6. - 'docs/**'
  7. - 'files/**'
  8. permissions:
  9. contents: read
  10. jobs:
  11. test:
  12. name: Lint, Unit, Unit addons, Circular dependencies & Examples testing
  13. runs-on: ubuntu-latest
  14. steps:
  15. - name: Git checkout
  16. uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6
  17. - name: Install Node
  18. uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6
  19. with:
  20. node-version: 24
  21. cache: 'npm'
  22. - name: Install dependencies
  23. run: npm ci
  24. - name: === Lint testing ===
  25. run: npm run lint
  26. - name: === Unit testing ===
  27. run: npm run test-unit
  28. - name: === Unit addons testing ===
  29. run: npm run test-unit-addons
  30. - name: === Examples ready for release ===
  31. run: npm run test-e2e-cov
  32. e2e:
  33. name: E2E testing
  34. runs-on: ${{ matrix.os }}
  35. timeout-minutes: 30
  36. strategy:
  37. fail-fast: false
  38. matrix:
  39. os: [ ubuntu-latest ]
  40. CI: [ 0, 1, 2, 3, 4 ]
  41. env:
  42. CI: ${{ matrix.CI }}
  43. steps:
  44. - name: Git checkout
  45. uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6
  46. - name: Install Node
  47. uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6
  48. with:
  49. node-version: 24
  50. cache: 'npm'
  51. - name: Install dependencies
  52. run: npm ci
  53. - name: Build
  54. run: npm run build-module
  55. - name: === E2E testing ===
  56. run: npm run test-e2e
  57. - name: Upload output screenshots
  58. uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5
  59. if: always()
  60. with:
  61. name: Output screenshots-${{ matrix.os }}-${{ matrix.CI }}
  62. path: test/e2e/output-screenshots
  63. if-no-files-found: ignore
粤ICP备19079148号