A library that computes the ephemerides.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

79 lines
1.8 KiB

  1. name: Tests
  2. on:
  3. push:
  4. branches: [main, features]
  5. pull_request:
  6. branches: [main, features]
  7. workflow_dispatch:
  8. jobs:
  9. tests:
  10. runs-on: ${{ matrix.os }}
  11. strategy:
  12. fail-fast: false
  13. matrix:
  14. os:
  15. - ubuntu-latest
  16. - macos-latest
  17. - windows-latest
  18. python_version:
  19. - '3.8'
  20. - '3.9'
  21. - '3.10'
  22. - '3.11'
  23. - '3.12'
  24. name: Python ${{ matrix.python_version }} (${{ matrix.os }})
  25. steps:
  26. - uses: actions/checkout@v4
  27. - name: Set up Python ${{ matrix.python_version }}
  28. uses: actions/setup-python@v5
  29. with:
  30. python-version: ${{ matrix.python_version }}
  31. - name: Prepare environment
  32. run: |
  33. python3 -m pip install --upgrade pip poetry
  34. - name: Install dependencies
  35. env:
  36. PIP_PREFER_BINARY: 1
  37. run: |
  38. python3 -m poetry install --with=dev
  39. - name: Run doc tests
  40. run: |
  41. make coverage-doctests
  42. - name: Push code coverage
  43. env:
  44. GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
  45. COVERALLS_PARALLEL: true
  46. COVERALLS_FLAG_NAME: "Py${{ matrix.python_version }}_${{ matrix.os }}"
  47. run: |
  48. python3 -m poetry run coveralls --service=github
  49. coverage:
  50. name: Push coverage report
  51. needs: tests
  52. runs-on: ubuntu-latest
  53. steps:
  54. - uses: actions/checkout@v4
  55. - name: Prepare Python
  56. uses: actions/setup-python@v5
  57. with:
  58. python-version: "3.x"
  59. - name: Install dependencies
  60. run: |
  61. pip install -U pip poetry
  62. poetry install
  63. - name: Upload coverage report
  64. run: |
  65. poetry run coveralls --finish --service=github
  66. env:
  67. GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}