From 23d8a0cdfb9c2ee00be770609dd2b7719a263120 Mon Sep 17 00:00:00 2001 From: Abhinav Saxena Date: Thu, 12 Jul 2018 12:31:32 +0530 Subject: [PATCH] add py36 support --- .travis.yml | 6 +++++- tox.ini | 35 ++++++++++++++++++++++++++++------- 2 files changed, 33 insertions(+), 8 deletions(-) diff --git a/.travis.yml b/.travis.yml index 822f3e5..6f64f63 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,6 +1,7 @@ language: python python: - '3.5' +- '3.6' virtualenv: system_site_packages: false sudo: false @@ -28,7 +29,10 @@ install: - export PYTHONIOENCODING=UTF8 - pip install coveralls - pip install -r requirements.txt +- tox -e cov-init script: -- tox +- if [[ $TRAVIS_PYTHON_VERSION == 3.5 ]]; then tox -e py35; fi +- if [[ $TRAVIS_PYTHON_VERSION == 3.6 ]]; then tox -e py36; fi after_success: +- tox -e cov-report - coveralls \ No newline at end of file diff --git a/tox.ini b/tox.ini index 9f66e1e..0e83f85 100644 --- a/tox.ini +++ b/tox.ini @@ -1,15 +1,14 @@ [tox] -envlist = py35 +envlist = py35, py36 skipsdist = True -usedevelop = True [testenv] -basepython = - py35: python3.5 +usedevelop = True passenv = * whitelist_externals = echo -description = run conpot tests in {envpython} -envdir = {toxinidir}/.tox/py35 +setenv = + COVERAGE_FILE = .coverage.{envname} + PYTHONDONTWRITEBYTECODE = pls deps = coverage pytest_timeout @@ -17,4 +16,26 @@ deps = pytest-cov commands = pip --default-timeout=1000 install -r requirements.txt - {envpython} -m pytest -rsx -v --timeout=30 --cov=telnetsrv {posargs} \ No newline at end of file + {envpython} -m pytest -rsx -v --timeout=30 --cov={toxinidir}/telnetsrv --cov-report term-missing + +[testenv:cov-init] +setenv = COVERAGE_FILE = .coverage +deps = coverage +commands = coverage erase + +[testenv:py35] +basepython = + py35: python3.5 +envdir = {toxinidir}/.tox/py35 + +[testenv:py36] +basepython = + py36: python3.6 +envdir = {toxinidir}/.tox/py36 + +[testenv:cov-report] +setenv = COVERAGE_FILE = .coverage +deps = coverage +commands = + coverage combine + coverage report \ No newline at end of file