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.

46 lines
992 B

4 years ago
4 years ago
  1. name: Django CI
  2. on:
  3. push:
  4. branches: [ master ]
  5. pull_request:
  6. branches: [ master ]
  7. jobs:
  8. build:
  9. runs-on: ubuntu-latest
  10. strategy:
  11. max-parallel: 4
  12. matrix:
  13. python-version: [3.6, 3.7, 3.8]
  14. services:
  15. postgres:
  16. image: postgres
  17. options: >-
  18. --health-cmd pg_isready
  19. --health-interval 10s
  20. --health-timeout 5s
  21. --health-retries 5
  22. ports:
  23. - 5432:5432
  24. steps:
  25. - uses: actions/checkout@v2
  26. - name: Set up Python ${{ matrix.python-version }}
  27. uses: actions/setup-python@v2
  28. with:
  29. python-version: ${{ matrix.python-version }}
  30. - name: Install Dependencies
  31. run: |
  32. python -m pip install --upgrade pip
  33. pip install -r requirements.txt
  34. pip install braintree mysqlclient apprise
  35. - name: Run Tests
  36. env:
  37. DB: postgres
  38. DB_HOST: localhost
  39. DB_PORT: 5432
  40. run: |
  41. python manage.py test