From: Thanh Ha Date: Mon, 27 Aug 2018 02:43:02 +0000 (-0400) Subject: Deduplicate test requirements X-Git-Tag: v0.17.0~2^2 X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F00%2F12400%2F1;p=releng%2Flftools.git Deduplicate test requirements Some of these tests being pulled in are duplicates. Let's consolidate into requirements-test.txt as the source of truth. Change-Id: I2481a364b9ddf2aa0ba9e2168d4ee408ca477c43 Signed-off-by: Thanh Ha --- diff --git a/setup.py b/setup.py index 79877a56..8e5aefb5 100644 --- a/setup.py +++ b/setup.py @@ -17,6 +17,10 @@ from setuptools import setup with open('requirements.txt') as f: install_reqs = f.read().splitlines() +with open('requirements-test.txt') as f: + f.readline() # Skip the first -rrequirements.txt line + test_reqs = f.read().splitlines() + setup( setup_requires=['pbr', 'pytest-runner'], pbr=True, @@ -27,5 +31,5 @@ setup( 'tests.*', 'tests' ]), - tests_require=['pytest'], + tests_require=test_reqs, ) diff --git a/tox.ini b/tox.ini index d62ad0e4..669343a2 100644 --- a/tox.ini +++ b/tox.ini @@ -10,12 +10,7 @@ envlist = py3 [testenv] -deps = - -r{toxinidir}/requirements.txt - -r{toxinidir}/requirements-test.txt - pytest - pytest-click - pytest-datafiles +deps = -r{toxinidir}/requirements-test.txt commands = pytest [testenv:check-hooks]