Skip to content

Commit 1ccf9fa

Browse files
Make test-library workflow poetry-aware
1 parent 36aa28a commit 1ccf9fa

1 file changed

Lines changed: 7 additions & 13 deletions

File tree

.github/workflows/test-library.yml

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -47,26 +47,20 @@ jobs:
4747
uses: actions/setup-python@v3
4848
with:
4949
python-version: ${{ matrix.python-version }}
50-
- name: Set up pipenv
51-
uses: actions/cache@v4
52-
with:
53-
path: ~/.local/share/virtualenvs
54-
key: ${{ runner.os }}-pipenv-${{ hashfiles('**/Pipfile.lock') }}
55-
restore-keys: |
56-
${{ runner.os }}-pipenv-
5750
- name: Install dependencies
5851
run: |
5952
python -m pip install --upgrade pip
60-
python -m pip install pipenv
61-
pipenv install --python ${{ matrix.python-version }}
62-
pipenv install flake8 pytest
53+
pip install poetry
54+
poetry install --no-root
55+
poetry add flake8
56+
poetry add pytest
6357
- name: Lint with flake8
6458
run: |
6559
# stop the build if there are Python syntax errors or undefined names
66-
pipenv run flake8 . --count --select=E9,F63,F7,F82 --ignore=F405,W391,W291,C901,E501,E303,W293 --exclude=examples,generator --show-source --statistics
60+
poetry run flake8 . --count --select=E9,F63,F7,F82 --ignore=F405,W391,W291,C901,E501,E303,W293 --exclude=examples,generator --show-source --statistics
6761
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
68-
pipenv run flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
62+
poetry run flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
6963
- name: Test with pytest
7064
run: |
71-
pipenv run pytest --apikey ${{ secrets.TEST_ORG_API_KEY }} --o ${{ secrets.TEST_ORG_ID }}
65+
poetry run pytest --apikey ${{ secrets.TEST_ORG_API_KEY }} --o ${{ secrets.TEST_ORG_ID }}
7266

0 commit comments

Comments
 (0)