2020 # ----------------------------------------------
2121 # load pip cache if cache exists
2222 # ----------------------------------------------
23- - uses : actions/cache@v3
23+ - uses : actions/cache@v4
2424 with :
2525 path : ~/.cache/pip
2626 key : ${{ runner.os }}-pip
@@ -37,20 +37,23 @@ jobs:
3737 test :
3838 needs : linting
3939 strategy :
40- fail-fast : true
40+ fail-fast : false
4141 matrix :
42- os : [ "ubuntu-latest", "macos-latest" ]
42+ os : ["ubuntu-latest", "macos-latest", "windows-latest" ]
4343 python-version : [ "3.11"]
4444 runs-on : ${{ matrix.os }}
45+ defaults :
46+ run :
47+ shell : bash
4548 steps :
4649 # ----------------------------------------------
4750 # check-out repo and set-up python
4851 # ----------------------------------------------
4952 - name : Check out repository
50- uses : actions/checkout@v3
53+ uses : actions/checkout@v5
5154 - name : Set up python ${{ matrix.python-version }}
5255 id : setup-python
53- uses : actions/setup-python@v4
56+ uses : actions/setup-python@v6
5457 with :
5558 python-version : ${{ matrix.python-version }}
5659 # ----------------------------------------------
6467 # ----------------------------------------------
6568 # load cached venv if cache exists
6669 # ----------------------------------------------
67- - name : Load cached venv
70+ - name : Load cached Venv
6871 id : cached-poetry-dependencies
69- uses : actions/cache@v3
72+ uses : actions/cache@v4
7073 with :
7174 path : .venv
7275 key : venv-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}
@@ -75,16 +78,29 @@ jobs:
7578 # ----------------------------------------------
7679 - name : Install dependencies
7780 if : steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
78- run : poetry install --no-interaction --no-root
81+ run : poetry install --no-interaction
7982 # ----------------------------------------------
8083 # install your root project, if required
8184 # ----------------------------------------------
8285 - name : Install library
83- run : poetry install --no-interaction --no-root
86+ run : poetry install --no-interaction
8487 # ----------------------------------------------
8588 # run test suite
8689 # ----------------------------------------------
87- - name : Run tests
90+ - name : Run tests (Linux, full)
91+ if : matrix.os == 'ubuntu-latest'
8892 run : |
8993 source .venv/bin/activate
90- pytest tests/
94+ pytest tests/
95+
96+ - name : Run tests (macOS)
97+ if : matrix.os == 'macos-latest'
98+ run : |
99+ source .venv/bin/activate
100+ pytest tests/
101+
102+ - name : Run tests (Windows)
103+ if : matrix.os == 'windows-latest'
104+ run : |
105+ source .venv/Scripts/activate
106+ pytest tests/
0 commit comments