Skip to content

Commit

Permalink
Use docker instances to run tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ymattw committed Jun 21, 2024
1 parent 2e78187 commit fa0b4e5
Showing 1 changed file with 12 additions and 16 deletions.
28 changes: 12 additions & 16 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,11 @@ concurrency:

jobs:
tests:
name: "Python ${{ matrix.python-version }} on ${{ matrix.os }}"
runs-on: "${{ matrix.os }}"
name: "Python ${{ matrix.python-version }}"
runs-on: ubuntu-latest

strategy:
matrix:
os:
- ubuntu-latest
- macos-latest
python-version:
# Available versions:
# https://github.com/actions/python-versions/blob/main/versions-manifest.json
Expand All @@ -43,15 +40,14 @@ jobs:
- name: "Check out the repo"
uses: "actions/checkout@v3"

- name: "Set up Python"
uses: "actions/setup-python@v4"
- name: "Run tests in Docker"
uses: "addnab/docker-run-action@v3"
with:
python-version: "${{ matrix.python-version }}"

- name: "Install dependencies"
run: |
python3 -VV
python3 -m pip install -r requirements-dev.txt
- name: "Run tests"
run: |
make test
image: "python:${{ matrix.python-version }}-alpine"
options: --rm -v ${{ github.workspace }}:/workspace
run: |
set -o errexit
apk add --no-cache bash less make
cd /workspace
python3 -m pip install -r requirements-dev.txt
make test

0 comments on commit fa0b4e5

Please sign in to comment.