Test workflow from upstream
This commit is contained in:
parent
28c4a0d80a
commit
ffa8553bac
1 changed files with 40 additions and 15 deletions
55
.github/workflows/test.yml
vendored
55
.github/workflows/test.yml
vendored
|
@ -1,21 +1,46 @@
|
||||||
name: Test
|
name: Tests
|
||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request:
|
workflow_dispatch:
|
||||||
push:
|
push:
|
||||||
branches:
|
paths-ignore:
|
||||||
- master
|
- 'LICENSE'
|
||||||
- stable*
|
- '**.md'
|
||||||
|
pull_request:
|
||||||
|
paths-ignore:
|
||||||
|
- 'LICENSE'
|
||||||
|
- '**.md'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
run-test-debian:
|
unit:
|
||||||
|
name: Unit Tests
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
base_docker_image: [alpine, debian]
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@v2
|
||||||
uses: actions/checkout@v2
|
|
||||||
- name: Setup Docker
|
- name: Set up Python 3.9
|
||||||
uses: docker-practice/actions-setup-docker@master
|
uses: actions/setup-python@v2
|
||||||
- name: Print docker version
|
with:
|
||||||
run: docker version
|
python-version: 3.9
|
||||||
- name: Run Makefile
|
|
||||||
run: make test-debian
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
python -m pip install --upgrade pip
|
||||||
|
pip install -r python-requirements.txt
|
||||||
|
working-directory: test/requirements
|
||||||
|
|
||||||
|
- name: Build Docker web server image
|
||||||
|
run: make build-webserver
|
||||||
|
|
||||||
|
- name: Build Docker nginx proxy test image
|
||||||
|
run: make build-nginx-proxy-test-${{ matrix.base_docker_image }}
|
||||||
|
|
||||||
|
- name: Run tests
|
||||||
|
run: pytest
|
||||||
|
working-directory: test
|
Loading…
Reference in a new issue