From 79f2161b88f8dbdf0a00dfa1b06a3f96a1f70b6b Mon Sep 17 00:00:00 2001 From: Chewing_Bever Date: Sat, 24 Apr 2021 22:22:12 +0200 Subject: [PATCH] Added (hopefully) complete tox config --- .woodpecker.yml | 31 +++++++++++++++++++++++++++++-- Makefile | 4 ++++ tests/test_succeed.py | 2 ++ tox.ini | 9 ++++++++- 4 files changed, 43 insertions(+), 3 deletions(-) create mode 100644 tests/test_succeed.py diff --git a/.woodpecker.yml b/.woodpecker.yml index 6e194d9..1067855 100644 --- a/.woodpecker.yml +++ b/.woodpecker.yml @@ -1,8 +1,35 @@ pipeline: # TODO add config for all other versions - text-3.9-current: - image: python:3.9 + test-3.9: + image: python:3.9-alpine pull: true commands: - pip install -e .[dev] - tox -e py39 + + test-3.8: + image: python:3.8-alpine + pull: true + commands: + - pip install -e .[dev] + - tox -e py38 + + test-3.7: + image: python:3.7-alpine + pull: true + commands: + - pip install -e .[dev] + - tox -e py37 + + test-3.6: + image: python:3.6-alpine + pull: true + commands: + - pip install -e .[dev] + - tox -e py36 + + lint: + image: python:3.6-alpine + commands: + - pip install -e .[dev] + - tox -e lint diff --git a/Makefile b/Makefile index 5c6d19b..3bf01a4 100644 --- a/Makefile +++ b/Makefile @@ -39,3 +39,7 @@ install: app test: venv tox.ini @ .venv/bin/tox .PHONY: test + +lint: venv + @ .venv/bin/tox -e lint +.PHONY: lint diff --git a/tests/test_succeed.py b/tests/test_succeed.py new file mode 100644 index 0000000..a5797d6 --- /dev/null +++ b/tests/test_succeed.py @@ -0,0 +1,2 @@ +def test_succeed(): + pass diff --git a/tox.ini b/tox.ini index 0df47e0..3dd1159 100644 --- a/tox.ini +++ b/tox.ini @@ -1,7 +1,14 @@ [tox] -envlist = py36,py37,py38,py39 +envlist = py36,py37,py38,py39,lint [testenv] deps = pytest commands = pytest + +[testenv:lint] +basepython = python3.6 +deps = black==20.8b1 + flake8==3.8.4 +commands = black --check setup.py app + flake8 setup.py app