File tree 4 files changed +58
-10
lines changed 4 files changed +58
-10
lines changed Original file line number Diff line number Diff line change 1
1
__pycache__
2
2
* .pyc
3
3
.idea
4
+ * .egg-info /
5
+ .tox /
Original file line number Diff line number Diff line change 1
- # vim ft=yaml
2
1
dist : xenial
3
2
language : python
4
3
@@ -9,19 +8,23 @@ python:
9
8
- " 3.6"
10
9
- " 3.7"
11
10
11
+ matrix :
12
+ include :
13
+ - python : " 2.7"
14
+ env : TOXENV=ci27
15
+ - python : " 3.6"
16
+ env : TOXENV=ci36
17
+ - python : " 3.7"
18
+ env : TOXENV=ci37
19
+
12
20
cache :
13
21
- pip
14
22
15
23
install :
16
- - pip install -r requirements-dev.txt
24
+ - pip install tox
17
25
18
26
script :
19
- - if [ "${TRAVIS_PYTHON_VERSION:0:1}" = 2 ]; then export PYEXCLUDE=3; else export PYEXCLUDE=2; fi
20
- - flake8 --exclude="*__py${PYEXCLUDE}.py" patterns/
21
- - pytest --doctest-modules --ignore-glob="*__py${PYEXCLUDE}.py" patterns/
22
- - pytest -s -vv --cov=. --log-level=INFO tests/
23
- # Actually run all the scripts, contributing to coverage
24
- - PYTHONPATH=. ./run_all.sh
27
+ - tox
25
28
26
29
after_success :
27
30
- codecov
Original file line number Diff line number Diff line change 1
- from setuptools import setup
1
+ from setuptools import setup , find_packages
2
2
3
3
setup (
4
- name = "python-patterns" ,
4
+ name = "patterns" ,
5
+ packages = find_packages (),
5
6
description = "A collection of design patterns and idioms in Python." ,
6
7
classifiers = [
7
8
"Programming Language :: Python :: 2" ,
Original file line number Diff line number Diff line change
1
+ [tox]
2
+ envlist = ci27,ci36,ci37,cov-report
3
+
4
+
5
+ [testenv]
6
+ setenv =
7
+ COVERAGE_FILE = .coverage.{envname}
8
+
9
+ [testenv:ci27]
10
+ basepython = python2.7
11
+ deps =
12
+ -r requirements-dev.txt
13
+ commands =
14
+ flake8 --exclude =" *__py3.py" patterns/
15
+ pytest --doctest-modules --ignore-glob =" *__py3.py" patterns/
16
+ pytest -s -vv --cov ={envsitepackagesdir}/patterns --log-level =INFO tests/
17
+
18
+ [testenv:ci36]
19
+ basepython = python3.6
20
+ deps =
21
+ -r requirements-dev.txt
22
+ commands =
23
+ flake8 --exclude =" *__py2.py" patterns/
24
+ pytest --doctest-modules --ignore-glob =" *__py2.py" patterns/
25
+ pytest -s -vv --cov ={envsitepackagesdir}/patterns --log-level =INFO tests/
26
+
27
+ [testenv:ci37]
28
+ basepython = python3.7
29
+ deps =
30
+ -r requirements-dev.txt
31
+ commands =
32
+ flake8 --exclude =" *__py2.py" patterns/
33
+ pytest --doctest-modules --ignore-glob =" *__py2.py" patterns/
34
+ pytest -s -vv --cov ={envsitepackagesdir}/patterns --log-level =INFO tests/
35
+
36
+ [testenv:cov-report]
37
+ setenv =
38
+ COVERAGE_FILE = .coverage
39
+ deps = coverage
40
+ commands =
41
+ coverage combine
42
+ coverage report
You can’t perform that action at this time.
0 commit comments