diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index bdb2c7f4206e55a535eaf638272f2feca4d33bf8..e9a4888076114dace80c85dfa815cbd4efdc5060 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -30,7 +30,7 @@ stages: # List of stages for jobs, and their order of execution - build - deploy -unit-test-job: +unit-test-job: stage: test script: - make test 2>&1 | tee errors.log @@ -41,6 +41,42 @@ unit-test-job: reports: junit: nose2-junit.xml +unit-test-2.7-job: + image: ${CI_DEPENDENCY_PROXY_DIRECT_GROUP_IMAGE_PREFIX}/python:2.7 + stage: test + script: + - make test + +unit-test-3.7-job: + image: ${CI_DEPENDENCY_PROXY_DIRECT_GROUP_IMAGE_PREFIX}/python:3.7 + stage: test + script: + - make test 2>&1 | tee errors-3.7.log + artifacts: + when: always + paths: + - errors-3.7.log + +unit-test-3.8-job: + image: ${CI_DEPENDENCY_PROXY_DIRECT_GROUP_IMAGE_PREFIX}/python:3.8 + stage: test + script: + - make test 2>&1 | tee errors-3.8.log + artifacts: + when: always + paths: + - errors-3.8.log + +unit-test-3.9-job: + image: ${CI_DEPENDENCY_PROXY_DIRECT_GROUP_IMAGE_PREFIX}/python:3.9 + stage: test + script: + - make test 2>&1 | tee errors-3.9.log + artifacts: + when: always + paths: + - errors-3.9.log + pylint-test-job: stage: test script: @@ -58,6 +94,27 @@ check-deprecation-warnings: - "if [[ $(grep DeprecationWarning errors.log) ]]; then cat errors.log; exit 1; fi" allow_failure: true +check-deprecation-warnings-3.7: + before_script: [] + stage: check-warnings + script: + - "if [[ $(grep DeprecationWarning errors-3.7.log) ]]; then cat errors-3.7.log; exit 1; fi" + allow_failure: true + +check-deprecation-warnings-3.8: + before_script: [] + stage: check-warnings + script: + - "if [[ $(grep DeprecationWarning errors-3.8.log) ]]; then cat errors-3.8.log; exit 1; fi" + allow_failure: true + +check-deprecation-warnings-3.9: + before_script: [] + stage: check-warnings + script: + - "if [[ $(grep DeprecationWarning errors-3.9.log) ]]; then cat errors-3.9.log; exit 1; fi" + allow_failure: true + build-job: stage: build script: diff --git a/Makefile b/Makefile index 7ccb587889b78ae9eb68abd3aa31f69d9cf36e36..6a07d0874e900a5099cdccd5a0c3179f65d630f1 100644 --- a/Makefile +++ b/Makefile @@ -98,7 +98,7 @@ help: show-version: FORCE - @PYTHONPATH=lib python3 -c "import typedcols; print(typedcols.__version__);" + @PYTHONPATH=lib python -c "import typedcols; print(typedcols.__version__);" #------------------------------------------------------------------------------- @@ -108,13 +108,13 @@ deps: deps-python deps-python-dev deps-python-dev: FORCE @echo "\n$(GREEN)*** Installing Python development dependencies ***$(NC)\n" - @pip3 --version - @pip3 install -r requirements-dev.pip + @pip --version + @pip install -r requirements-dev.pip deps-python: FORCE @echo "\n${GREEN}*** Installing Python dependencies ***${NC}\n" @echo "\nThis project does not have any dependencies, nothing to do here...\n" - @#pip3 install -r requirements.pip --upgrade + @#pip install -r requirements.pip --upgrade #------------------------------------------------------------------------------- @@ -138,11 +138,11 @@ pyflakes: pyflakes-lib: FORCE @echo "\n${GREEN}*** Checking code with pyflakes ***${NC}\n" - -@python3 -m pyflakes typedcols.py + -@python -m pyflakes typedcols.py pyflakes-test: FORCE @echo "\n${GREEN}*** Checking test files with pyflakes ***${NC}\n" - -@python3 -m pyflakes test_typedcols.py + -@python -m pyflakes test_typedcols.py #pylint: pylint-lib pylint-test pylint: @@ -150,15 +150,15 @@ pylint: pylint-lib: FORCE @echo "\n${GREEN}*** Checking code with pylint ***${NC}\n" - -@python3 -m pylint typedcols.py --rcfile .pylintrc-lib + -@python -m pylint typedcols.py --rcfile .pylintrc-lib pylint-test: FORCE @echo "\n${GREEN}*** Checking test files with pylint ***${NC}\n" - -@python3 -m pylint test_typedcols.py --rcfile .pylintrc-test + -@python -m pylint test_typedcols.py --rcfile .pylintrc-test test: FORCE @echo "\n${GREEN}*** Checking code with nosetests ***${NC}\n" - @python3 -W always::DeprecationWarning -m nose2 --junit-xml + @python -W always::DeprecationWarning -m nose2 --junit-xml #------------------------------------------------------------------------------- @@ -172,11 +172,11 @@ archive: FORCE bdist: FORCE @echo "\n${GREEN}*** Building Python packages ***${NC}\n" - @python3 setup.py sdist bdist_wheel --universal + @python setup.py sdist bdist_wheel --universal install: FORCE @echo "\n${GREEN}*** Performing local installation ***${NC}\n" - @pip3 install dist/typedcols*.whl --upgrade + @pip install dist/typedcols*.whl --upgrade deploy: FORCE @echo "\n${GREEN}*** Deploying packages to PyPI ***${NC}\n" diff --git a/requirements-dev.pip b/requirements-dev.pip index 43b6e13a2bcb7079e2a246c3060436790616bfb2..3169a2b2980b31b608b1b396be2129cd59aedb4a 100644 --- a/requirements-dev.pip +++ b/requirements-dev.pip @@ -3,7 +3,7 @@ wheel twine docutils<0.18 nose2==0.11.0 -pyflakes==2.1.0 -pylint==2.2.2 +pyflakes +pylint sphinx==1.8.4 sphinx-rtd-theme==0.4.2