mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
change python version in tests from 3.7 to 3.9
This commit is contained in:
parent
8aae994720
commit
7ff1ce5432
2 changed files with 13 additions and 14 deletions
|
@ -3,21 +3,20 @@
|
|||
########################################
|
||||
# later we must fix lint and format-check jobs and remove "allow_failure"
|
||||
|
||||
---
|
||||
lint37:
|
||||
lint39:
|
||||
stage: lint
|
||||
image: "before-install"
|
||||
needs: []
|
||||
allow_failure: true
|
||||
script:
|
||||
- tox -e py37-lint
|
||||
- tox -e py39-lint
|
||||
|
||||
invalidcode37:
|
||||
invalidcode39:
|
||||
stage: lint
|
||||
image: "before-install"
|
||||
needs: []
|
||||
script:
|
||||
- tox -e py37-invalidcode
|
||||
- tox -e py39-invalidcode
|
||||
|
||||
format-check:
|
||||
stage: lint
|
||||
|
@ -25,7 +24,7 @@ format-check:
|
|||
allow_failure: true
|
||||
needs: []
|
||||
script:
|
||||
- tox -e py37-black-check
|
||||
- tox -e py39-black-check
|
||||
|
||||
format-run:
|
||||
stage: lint
|
||||
|
@ -40,7 +39,7 @@ format-run:
|
|||
script:
|
||||
# create a local branch that will overwrite distant one
|
||||
- git checkout -b "ci-format-${CI_COMMIT_REF_NAME}" --no-track
|
||||
- tox -e py37-black-run
|
||||
- tox -e py39-black-run
|
||||
- '[ $(git diff | wc -l) != 0 ] || exit 0' # stop if there is nothing to commit
|
||||
- git commit -am "[CI] Format code" || true
|
||||
- git push -f origin "ci-format-${CI_COMMIT_REF_NAME}":"ci-format-${CI_COMMIT_REF_NAME}"
|
||||
|
|
14
tox.ini
14
tox.ini
|
@ -1,13 +1,13 @@
|
|||
[tox]
|
||||
envlist = py37-{lint,invalidcode},py37-black-{run,check}
|
||||
envlist = py39-{lint,invalidcode},py39-black-{run,check}
|
||||
|
||||
[testenv]
|
||||
skip_install=True
|
||||
deps =
|
||||
py37-{lint,invalidcode}: flake8
|
||||
py37-black-{run,check}: black
|
||||
py39-{lint,invalidcode}: flake8
|
||||
py39-black-{run,check}: black
|
||||
commands =
|
||||
py37-lint: flake8 src doc data tests --ignore E402,E501,E203,W503 --exclude src/yunohost/vendor
|
||||
py37-invalidcode: flake8 src data --exclude src/yunohost/tests,src/yunohost/vendor --select F
|
||||
py37-black-check: black --check --diff src doc data tests
|
||||
py37-black-run: black src doc data tests
|
||||
py39-lint: flake8 src doc data tests --ignore E402,E501,E203,W503 --exclude src/yunohost/vendor
|
||||
py39-invalidcode: flake8 src data --exclude src/yunohost/tests,src/yunohost/vendor --select F
|
||||
py39-black-check: black --check --diff src doc data tests
|
||||
py39-black-run: black src doc data tests
|
||||
|
|
Loading…
Add table
Reference in a new issue