diff options
Diffstat (limited to '')
-rw-r--r-- | .github/workflows/tests.yml | 242 |
1 files changed, 242 insertions, 0 deletions
diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml new file mode 100644 index 0000000..22a19f3 --- /dev/null +++ b/.github/workflows/tests.yml @@ -0,0 +1,242 @@ +name: Distribution Checks + +on: + - push + - pull_request + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +permissions: read-all + +jobs: + + alma-9: + # At the time of adding this test, tox and pytest don't install + # cleanly using system packages, so just run the integration tests + # for now. + name: AlmaLinux 9 + runs-on: ubuntu-latest + container: almalinux:9 + steps: + - run: | + dnf -y install \ + python3 \ + python3-pyyaml + - uses: actions/checkout@v1 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + alma-8: + name: AlmaLinux 8 + runs-on: ubuntu-latest + container: almalinux:8 + steps: + - run: | + yum -y install \ + python2-pytest \ + python2-pyyaml \ + python3 \ + python3-pytest \ + python3-pyyaml + - uses: actions/checkout@v1 + + - name: Python 2 unit tests + run: PYTHONPATH=. pytest-2 + - name: Python 2 integration tests + run: PYTHONPATH=. python2 ./tests/integration_tests.py + + - name: Python 3 unit tests + run: PYTHONPATH=. pytest-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + centos-7: + name: CentOS 7 + runs-on: ubuntu-latest + container: centos:7 + steps: + - run: yum -y install epel-release + - run: | + yum -y install \ + python2-pytest \ + python2-pyyaml \ + python36-pytest \ + python36-yaml + - uses: actions/checkout@v1 + + - name: Python 2 unit tests + run: PYTHONPATH=. py.test-2.7 + - name: Python 2 integration tests + run: PYTHONPATH=. python2 ./tests/integration_tests.py + + - name: Python 3 unit tests + run: PYTHONPATH=. py.test-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + fedora-39: + name: Fedora 39 + runs-on: ubuntu-latest + container: fedora:39 + steps: + - run: | + dnf -y install \ + python3 \ + python3-pytest \ + python3-pyyaml + - uses: actions/checkout@v4 + - name: Python 3 unit tests + run: PYTHONPATH=. pytest-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + fedora-38: + name: Fedora 38 + runs-on: ubuntu-latest + container: fedora:38 + steps: + - run: | + dnf -y install \ + python3 \ + python3-pytest \ + python3-pyyaml + - uses: actions/checkout@v2 + - name: Python 3 unit tests + run: PYTHONPATH=. pytest-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + ubuntu-2204: + name: Ubuntu 22.04 + runs-on: ubuntu-latest + container: ubuntu:22.04 + steps: + - run: apt update + - run: | + apt -y install \ + python3-pytest \ + python3-yaml + - uses: actions/checkout@v1 + - name: Python 3 unit tests + run: PYTHONPATH=. pytest-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + ubuntu-2004: + name: Ubuntu 20.04 + runs-on: ubuntu-latest + container: ubuntu:20.04 + steps: + - run: apt update + - run: | + apt -y install \ + python-pytest \ + python-yaml \ + python3-pytest \ + python3-yaml + - uses: actions/checkout@v1 + + - name: Python 2 unit tests + run: PYTHONPATH=. pytest + - name: Python 2 integration tests + run: PYTHONPATH=. python2 ./tests/integration_tests.py + + - name: Python 3 unit tests + run: PYTHONPATH=. pytest-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + ubuntu-1804: + name: Ubuntu 18.04 + runs-on: ubuntu-latest + container: ubuntu:18.04 + steps: + - run: apt update + - run: | + apt -y install \ + python-pytest \ + python-yaml \ + python3-pytest \ + python3-yaml + - uses: actions/checkout@v1 + + - name: Python 2 unit tests + run: PYTHONPATH=. pytest + - name: Python 2 integration tests + run: PYTHONPATH=. python2 ./tests/integration_tests.py + + - name: Python 3 unit tests + run: PYTHONPATH=. pytest-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + debian-12: + name: Debian 12 + runs-on: ubuntu-latest + container: debian:12 + steps: + - run: apt update + - run: | + apt -y install \ + python3-pytest \ + python3-yaml + - uses: actions/checkout@v1 + + - name: Python 3 unit tests + run: PYTHONPATH=. pytest-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + debian-11: + name: Debian 11 + runs-on: ubuntu-latest + container: debian:11 + steps: + - run: apt update + - run: | + apt -y install \ + python3-pytest \ + python3-yaml + - uses: actions/checkout@v1 + + - name: Python 3 unit tests + run: PYTHONPATH=. pytest-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + debian-10: + name: Debian 10 + runs-on: ubuntu-latest + container: debian:10 + steps: + - run: apt update + - run: | + apt -y install \ + python-pytest \ + python-yaml \ + python3-pytest \ + python3-yaml + - uses: actions/checkout@v1 + + - name: Python 2 unit tests + run: PYTHONPATH=. pytest + - name: Python 2 integration tests + run: PYTHONPATH=. python2 ./tests/integration_tests.py + + - name: Python 3 unit tests + run: PYTHONPATH=. pytest-3 + - name: Python 3 integration tests + run: PYTHONPATH=. python3 ./tests/integration_tests.py + + macos-latest: + name: MacOS Latest + runs-on: macos-latest + steps: + - run: brew install python + - run: pip3 install PyYAML + - run: pip3 install pytest + - uses: actions/checkout@v1 + - run: PYTHONPATH=. python3 -m pytest + - run: PYTHONPATH=. python3 ./tests/integration_tests.py |