@@ -27,36 +27,34 @@ jobs:
2727 fail-fast : false
2828
2929 steps :
30- - name : Checkout source code
30+ - name : Checkout repo
3131 uses : actions/checkout@v4
3232 - name : Set up .env
3333 run : cp ./.env.template ./.env
3434 - name : Run docker-compose with Splunk v${{ matrix.splunk-version }}
3535 run : SPLUNK_VERSION=${{ matrix.splunk-version }} docker compose up -d
36- - name : Restore cached virtualenv
36+ - name : Restore cached venv and .tox
3737 id : restore-venv-cache
3838 uses : actions/cache/restore@v4
3939 with :
40- path : ./venv
41- key : ${{ runner.os }}-${{ matrix.python }}-venv-${{ hashFiles('**/pyproject.toml') }}
42- - name : Setup Python ${{ matrix.python }}
43- uses : actions/setup-python@v5
44- if : steps.restore-venv-cache.outputs.cache-hit != 'true'
45- with :
46- python-version : ${{ matrix.python }}
47-
40+ path : |
41+ ./venv
42+ ./.tox
43+ key : ${{ runner.os }}-3.9-venv-${{ hashFiles('**/pyproject.toml') }}
4844 - name : Build venv
4945 if : steps.restore-venv-cache.outputs.cache-hit != 'true'
5046 run : |
5147 python -m venv ./venv
52- python -m pip install .
48+ ./venv/bin/ python -m pip install .
5349 - name : Run test suite
5450 run : ./venv/bin/python -m tox -e py
55- - name : Cache virtualenv
51+ - name : Cache venv and .tox
5652 uses : actions/cache/save@v4
5753 if : steps.restore-venv-cache.outputs.cache-hit != 'true'
5854 with :
59- path : ./venv
55+ path : |
56+ ./venv
57+ ./.tox
6058 key : ${{ steps.restore-venv-cache.outputs.cache-primary-key }}
6159# [BJ] I'll obviously uncomment this step after I finish fiddling
6260# fossa-scan:
0 commit comments