2020-12-01 10:02:31 +00:00
|
|
|
name: Test Supported Distributions
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
types: [opened, synchronize, reopened, ready_for_review]
|
|
|
|
|
|
|
|
jobs:
|
2021-10-05 18:34:51 +00:00
|
|
|
smoke-test:
|
|
|
|
if: github.event.pull_request.draft == false
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
-
|
|
|
|
name: Checkout repository
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
-
|
|
|
|
name: Run Smoke Tests
|
|
|
|
run: |
|
|
|
|
# Ensure scripts in repository are executable
|
|
|
|
IFS=$'\n';
|
|
|
|
for f in $(find . -name '*.sh'); do if [[ ! -x $f ]]; then echo "$f is not executable" && FAIL=1; fi ;done
|
|
|
|
unset IFS;
|
|
|
|
# If FAIL is 1 then we fail.
|
|
|
|
[[ $FAIL == 1 ]] && exit 1 || echo "Smoke Tests Passed"
|
|
|
|
|
2020-12-01 10:02:31 +00:00
|
|
|
distro-test:
|
|
|
|
if: github.event.pull_request.draft == false
|
|
|
|
runs-on: ubuntu-latest
|
2021-10-05 18:34:51 +00:00
|
|
|
needs: smoke-test
|
2020-12-01 10:02:31 +00:00
|
|
|
strategy:
|
|
|
|
matrix:
|
2021-10-23 18:43:20 +00:00
|
|
|
distro: [debian_9, debian_10, debian_11, ubuntu_16, ubuntu_18, ubuntu_20, ubuntu_21, centos_7, centos_8, fedora_33, fedora_34]
|
2020-12-01 10:02:31 +00:00
|
|
|
env:
|
2020-12-01 10:09:16 +00:00
|
|
|
DISTRO: ${{matrix.distro}}
|
|
|
|
steps:
|
2021-10-05 18:34:51 +00:00
|
|
|
-
|
|
|
|
name: Checkout repository
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
-
|
2021-11-18 01:03:37 +00:00
|
|
|
name: Set up Python 3.8
|
2020-12-01 10:02:31 +00:00
|
|
|
uses: actions/setup-python@v2
|
|
|
|
with:
|
2021-11-18 01:03:37 +00:00
|
|
|
python-version: 3.8
|
2021-10-05 18:34:51 +00:00
|
|
|
-
|
|
|
|
name: Install dependencies
|
2020-12-01 10:02:31 +00:00
|
|
|
run: pip install -r test/requirements.txt
|
2021-10-05 18:34:51 +00:00
|
|
|
-
|
|
|
|
name: Test with tox
|
2020-12-01 10:02:31 +00:00
|
|
|
run: tox -c test/tox.${DISTRO}.ini
|