Browse Source

refactor test job: specify python version explicitly

https://github.com/fphammerle/switchbot-mqtt/commit/fcb34cee5e2edf199d6971555c8a5525b43ae2d6#diff-092659a9bd0068791326fb1d08f005532e5aeb983b999a7bd32c51deee0a71d5R49
Fabian Peter Hammerle 1 week ago
parent
commit
aaf6491c78
1 changed files with 3 additions and 1 deletions
  1. 3 1
      .github/workflows/python.yml

+ 3 - 1
.github/workflows/python.yml

@@ -45,7 +45,9 @@ jobs:
         python-version: ${{ matrix.python-version }}
     - run: pip install --upgrade pipenv==2020.8.13
     # by default pipenv picks the latest version in PATH
-    - run: pipenv --python "$(which python)" install --deploy --dev
+    - run: pipenv install --python "$PYTHON_VERSION" --deploy --dev
+      env:
+        PYTHON_VERSION: ${{ matrix.python-version }}
     - run: pipenv graph
     - run: pipenv run pytest --cov="$(cat *.egg-info/top_level.txt)" --cov-report=term-missing --cov-fail-under=100
     - run: pipenv run pylint --load-plugins=pylint_import_requirements "$(cat *.egg-info/top_level.txt)"