unit_test.yml 741 B

12345678910111213141516171819202122232425262728293031323334
  1. name: Unit test CI
  2. on:
  3. push:
  4. tags:
  5. - r**
  6. pull_request:
  7. jobs:
  8. build:
  9. runs-on: ubuntu-latest
  10. strategy:
  11. max-parallel: 4
  12. matrix:
  13. python-version: [ "3.10" ]
  14. steps:
  15. - uses: actions/checkout@v3
  16. - uses: actions/setup-python@v4
  17. with:
  18. python-version: ${{ matrix.python-version }}
  19. - name: Install Dependencies
  20. run: |
  21. python -m pip install --upgrade pip
  22. pip install -r requirements/test.txt
  23. - name: Create Database
  24. run: |
  25. python manage_test.py makemigrations
  26. python manage_test.py migrate
  27. - name: Run Unit Tests
  28. run: |
  29. coverage run manage_test.py test
  30. coverage report