Skip to content

Commit

Permalink
Factor venv setup into the venv creation step
Browse files Browse the repository at this point in the history
  • Loading branch information
EliahKagan committed Feb 14, 2024
1 parent dc3f5dc commit 4a4734b
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/alpine-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,24 +44,23 @@ jobs:
# and cause subsequent tests to fail
cat test/fixtures/.gitconfig >> ~/.gitconfig
- name: Create Python virtual environment
- name: Set up virtualenv
run: |
python -m venv .venv
. .venv/bin/activate
printf '%s=%s\n' 'PATH' "$PATH" 'VIRTUAL_ENV' "$VIRTUAL_ENV" >>"$GITHUB_ENV"
- name: Update PyPA packages
run: |
# Get the latest pip, wheel, and prior to Python 3.12, setuptools.
. .venv/bin/activate
python -m pip install -U pip $(pip freeze --all | grep -ow ^setuptools) wheel
- name: Install project and test dependencies
run: |
. .venv/bin/activate
pip install ".[test]"
- name: Show version and platform information
run: |
. .venv/bin/activate
uname -a
command -v git python
git version
Expand All @@ -70,5 +69,4 @@ jobs:
- name: Test with pytest
run: |
. .venv/bin/activate
pytest --color=yes -p no:sugar --instafail -vv

0 comments on commit 4a4734b

Please sign in to comment.