linuxtests.yml 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. name: Linux Tests
  2. on: [push, pull_request]
  3. jobs:
  4. linuxtests:
  5. name: Linux
  6. strategy:
  7. matrix:
  8. group: [integrity, integrity2, docs, usage, python, examples, nonode, linkcheck, lint]
  9. python: [3.6, 3.8]
  10. exclude:
  11. - group: integrity
  12. python: 3.6
  13. - group: integrity2
  14. python: 3.6
  15. - group: docs
  16. python: 3.6
  17. - group: usage
  18. python: 3.6
  19. - group: linkcheck
  20. python: 3.6
  21. - group: nonode
  22. python: 3.6
  23. - group: lint
  24. python: 3.6
  25. - group: examples
  26. python: 3.6
  27. fail-fast: false
  28. timeout-minutes: 120
  29. runs-on: ubuntu-latest
  30. steps:
  31. - uses: actions/checkout@v2
  32. - name: Set up Python
  33. uses: actions/setup-python@v1
  34. with:
  35. python-version: ${{ matrix.python }}
  36. - name: Set up Node
  37. uses: actions/setup-node@v1
  38. with:
  39. node-version: '12.x'
  40. - name: Cache pip on Linux
  41. uses: actions/cache@v1
  42. if: startsWith(runner.os, 'Linux')
  43. with:
  44. path: ~/.cache/pip
  45. key: ${{ runner.os }}-pip-${{ matrix.python }}-${{ hashFiles('**/requirements.txt') }}
  46. restore-keys: |
  47. ${{ runner.os }}-pip-${{ matrix.python }}
  48. - name: Get yarn cache directory path
  49. id: yarn-cache-dir-path
  50. run: echo "::set-output name=dir::$(yarn cache dir)"
  51. - name: Cache yarn
  52. uses: actions/cache@v1
  53. id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
  54. with:
  55. path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
  56. key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
  57. restore-keys: |
  58. ${{ runner.os }}-yarn-
  59. - name: Cache checked links build
  60. uses: actions/cache@v1
  61. if: ${{ matrix.group == 'docs' }}
  62. with:
  63. path: ~/.cache/pytest-link-check
  64. key: ${{ runner.os }}-link-check-${{ hashFiles('**/*.rst') }}
  65. restore-keys: |
  66. ${{ runner.os }}-link-check-
  67. - name: Install dependencies
  68. env:
  69. GROUP: ${{ matrix.group }}
  70. run: |
  71. bash ./scripts/ci_install.sh
  72. - name: Run test ${{ matrix.group }}
  73. env:
  74. GROUP: ${{ matrix.group }}
  75. run: |
  76. bash ./scripts/ci_script.sh