Skip to content
This repository was archived by the owner on Jun 1, 2023. It is now read-only.

Commit 0fb5779

Browse files
committed
Trying to get Travis to work
1 parent de8a67d commit 0fb5779

File tree

5 files changed

+47
-59
lines changed

5 files changed

+47
-59
lines changed

.isort.cfg

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[settings]
2+
force_single_line = 1
3+
known_first_party = oicmsg
4+
known_third_party = cryptojwt,pytest
5+
known_future_library = future,past
6+
default_section = THIRDPARTY

.travis.yml

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,28 @@
11
language: python
2-
python:
3-
- "3.5"
4-
- "3.6"
5-
# command to install dependencies
2+
3+
sudo: false
4+
5+
python: 3.6
6+
67
install:
7-
- pip install -r requirements.txt
8-
# command to run tests
8+
- pip install tox
9+
10+
env:
11+
- TOXENV=py34
12+
- TOXENV=py35
13+
- TOXENV=py36
14+
- TOXENV=py37
15+
- TOXENV=quality
16+
- TOXENV=docs
17+
18+
# Everything behaves under python 3.6 except python3.5
19+
matrix:
20+
include:
21+
- python: 3.5
22+
env: TOXENV=py35
23+
924
script:
10-
- pytest # or py.test for Python versions 3.5 and below
25+
- tox -e $TOXENV
26+
27+
notifications:
28+
email: false

pylama.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
max_line_length = 120
33

44
[pylama:mccabe]
5-
complexity = 40
5+
complexity = 32

requirements.txt

Lines changed: 0 additions & 6 deletions
This file was deleted.

tox.ini

Lines changed: 15 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,60 +1,30 @@
11
[tox]
2-
envlist = py{34,35,36,37},docs,quality
2+
envlist = py{34,35,36},docs,quality
33

44
[testenv]
5-
setenv =
6-
COVERAGE_FILE = {toxinidir}/.coverage.{envname}
7-
passenv = TRAVIS TRAVIS_JOB_ID TRAVIS_BRANCH
5+
passenv = CI TRAVIS TRAVIS_*
86
commands =
9-
pipenv install --dev
10-
pipenv run py.test --cov-report= --cov=oidc tests/ -m "not network" {posargs}
11-
; Transform absolute path to relative path for compatibility with coveralls.io and fix 'source not available' error.
12-
pipenv run python -c "import os;cov_strip_abspath = open(os.environ['COVERAGE_FILE'], 'r').read().replace('.tox' + os.sep + os.path.relpath('{envsitepackagesdir}', '{toxworkdir}'), 'src');open(os.environ['COVERAGE_FILE'], 'w').write(cov_strip_abspath)"
13-
deps = pipenv
7+
py.test --cov-report= --cov=oicmsg tests/ -m "not network" {posargs}
8+
codecov
9+
extras = testing
10+
deps =
11+
codecov
12+
pytest-cov
1413

1514
[testenv:docs]
1615
whitelist_externals = make
17-
deps = pipenv
18-
commands =
19-
pipenv install --dev
20-
make html
16+
extras = docs
17+
commands = sphinx-build -b html doc/ doc/_build/html -W
2118

2219
[testenv:quality]
23-
whitelist_externals = make
24-
deps = pipenv
25-
commands =
26-
pipenv install --dev
27-
make check-isort
28-
make check-pylama
29-
30-
[testenv:coveralls]
31-
setenv =
32-
COVERAGE_FILE = {toxinidir}/.coverage
33-
passenv =
34-
*
35-
deps =
36-
coverage
37-
coveralls
38-
skip_install = true
39-
commands =
40-
coverage combine
41-
coveralls
42-
changedir = {toxinidir}
43-
44-
[testenv:coverage-erase]
45-
setenv =
46-
COVERAGE_FILE = {toxinidir}/.coverage
47-
passenv =
48-
*
49-
deps =
50-
coverage
51-
skip_install = true
20+
ignore_errors = True
21+
extras = quality
5222
commands =
53-
coverage erase
54-
changedir = {toxinidir}
23+
isort --recursive --diff --check-only src/ tests/
24+
pylama src/ tests/
5525

5626
[pep8]
5727
max-line-length=100
5828

5929
[pytest]
60-
addopts = --color=yes
30+
addopts = --color=yes

0 commit comments

Comments
 (0)