test.yml 926 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. name: Tests
  2. on:
  3. workflow_dispatch:
  4. push:
  5. paths-ignore:
  6. - 'LICENSE'
  7. - '**.md'
  8. pull_request:
  9. paths-ignore:
  10. - 'LICENSE'
  11. - '**.md'
  12. jobs:
  13. unit:
  14. name: Unit Tests
  15. runs-on: ubuntu-latest
  16. strategy:
  17. matrix:
  18. base_docker_image: [alpine, debian]
  19. steps:
  20. - uses: actions/checkout@v2
  21. - name: Set up Python 3.9
  22. uses: actions/setup-python@v2
  23. with:
  24. python-version: 3.9
  25. - name: Install dependencies
  26. run: |
  27. python -m pip install --upgrade pip
  28. pip install -r python-requirements.txt
  29. working-directory: test/requirements
  30. - name: Build Docker web server image
  31. run: make build-webserver
  32. - name: Build Docker nginx proxy test image
  33. run: make build-nginx-proxy-test-${{ matrix.base_docker_image }}
  34. - name: Run tests
  35. run: pytest
  36. working-directory: test