From 7d17d6c54ff2a9e4bdef927d19c993a08c7c8b8c Mon Sep 17 00:00:00 2001 From: Harmon Date: Wed, 16 Oct 2019 09:59:33 -0500 Subject: [PATCH] Configure nosetests through setup.cfg Run Travis CI and tox tests through setuptools Use NOSE_WITH_COVERAGE environment variable for Travis CI --- .travis.yml | 3 ++- setup.cfg | 4 ++++ tests/travis-tests.cfg | 2 -- tox.ini | 2 +- 4 files changed, 7 insertions(+), 4 deletions(-) delete mode 100644 tests/travis-tests.cfg diff --git a/.travis.yml b/.travis.yml index 2231954..6caf473 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,6 +16,7 @@ env: global: - TWITTER_USERNAME="TweepyDev" - AWS_BUCKET="tweepy" + - NOSE_WITH_COVERAGE=1 - USE_REPLAY=1 - secure: TPQSFGqdl6khXqQqTZ6euROoAmFRnONAlPXD6npvTIIN+fNfnz8lvZtOEWHo2jRPLoU3FyVUhYvTynj6B2hJinulP+RKOMbQ65HCZVHrsitwl1n1QZB5HegQDOYc5q6VTTYn/r8r5tGy35U0O80y1zycTLqSJiXlkdqsSq564pI= @@ -23,7 +24,7 @@ install: - pip install .[dev,test] script: - - nosetests -v --with-coverage -c tests/travis-tests.cfg + - python setup.py nosetests after_success: - if [[ "$TRAVIS_PULL_REQUEST" == "false" ]]; then coveralls; fi diff --git a/setup.cfg b/setup.cfg index 2a9acf1..0a4a8a9 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,2 +1,6 @@ [bdist_wheel] universal = 1 + +[nosetests] +verbosity = 2 +tests = tests.test_api,tests.test_cursors,tests.test_resultset,tests.test_utils diff --git a/tests/travis-tests.cfg b/tests/travis-tests.cfg deleted file mode 100644 index b23d7d3..0000000 --- a/tests/travis-tests.cfg +++ /dev/null @@ -1,2 +0,0 @@ -[nosetests] -tests=tests.test_api,tests.test_cursors,tests.test_resultset,tests.test_utils diff --git a/tox.ini b/tox.ini index b88c0d9..d94e46a 100644 --- a/tox.ini +++ b/tox.ini @@ -7,7 +7,7 @@ envlist = py27, py35, py36, py37 [testenv] -commands = nosetests -v tests.test_api tests.test_cursors tests.test_resultset tests.test_utils +commands = python setup.py nosetests extras = test setenv = USE_REPLAY = 1 -- 2.25.1