Skip to content

Commit

Permalink
Add lint to CI; update CI to use make
Browse files Browse the repository at this point in the history
Added `make lint` as the first CI step, after which the test suite runs
for each environment. Updated the test suite to use `make test-env`
rather than calling `tox` directly.
  • Loading branch information
mplanchard committed Sep 7, 2019
1 parent 6dda28e commit 30d32ef
Showing 1 changed file with 34 additions and 9 deletions.
43 changes: 34 additions & 9 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,60 +1,85 @@
image: python:3

stages:
- lint
- test

lint:
image: python:3.7
stage: lint
script:
# Work around pylint not being able to figure out falcon imports when
# using manylinux wheels.
# See https://github.com/falconry/falcon/issues/1553 for details.
- make setup
- source venv/bin/activate; pip install no-manylinux
- "source venv/bin/activate; pip install --no-binary :all: --force-reinstall falcon"
- make lint

test-2.7:
image: python:2.7
stage: test
coverage: '/^TOTAL.*\s+(\d+\%)$/'
script:
- pip install tox
- tox -e py27

test-3.4:
image: python:3.4
stage: test
coverage: '/^TOTAL.*\s+(\d+\%)$/'
script:
- pip install tox
- tox -e py34

test-3.5-marshmallow-2:
image: python:3.5
stage: test
coverage: '/^TOTAL.*\s+(\d+\%)$/'
script:
- pip install tox
- tox -e py35-marshmallow2

test-3.5-marshmallow-3:
image: python:3.5
stage: test
coverage: '/^TOTAL.*\s+(\d+\%)$/'
script:
- pip install tox
- tox -e py35-marshmallow3

test-3.6-marshmallow-2:
image: python:3.6
stage: test
variables:
TESTENV: py36-marshmallow2
coverage: '/^TOTAL.*\s+(\d+\%)$/'
script:
- pip install tox
- tox -e py36-marshmallow2
- make test-env

test-3.6-marshmallow-2:
test-3.6-marshmallow-3:
image: python:3.6
stage: test
variables:
TESTENV: py36-marshmallow3
coverage: '/^TOTAL.*\s+(\d+\%)$/'
script:
- pip install tox
- tox -e py36-marshmallow3
- make test-env

test-3.7-marshmallow-2:
image: python:3.7
stage: test
variables:
TESTENV: py37-marshmallow2
coverage: '/^TOTAL.*\s+(\d+\%)$/'
script:
- pip install tox
- tox -e py37-marshmallow2
- make test-env

test-3.7-marshmallow-3:
image: python:3.7
stage: test
variables:
TESTENV: py37-marshmallow3
coverage: '/^TOTAL.*\s+(\d+\%)$/'
script:
- pip install tox
- tox -e py37-marshmallow3
- make test-env

0 comments on commit 30d32ef

Please sign in to comment.