diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 13e67a66114020e1b2b45fe901a9604160860964..51c2fffa23a7c14b2cd51ebd47416523fddc5942 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -2,6 +2,7 @@ image: $DOCKER_REGISTRY/pdsl/rdiffweb-build:$CI_PIPELINE_IID variables: PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip" + PIP_INDEX_URL: https://nexus.patrikdufresne.com/repository/pypi-proxy/simple/ stages: - prebuild diff --git a/setup.py b/setup.py index 56d314bc56b20edb69b4f7301bc1dd8bfca0cfb5..6c0cd0d409d18d12c1c7fdb207d728e9485957ef 100644 --- a/setup.py +++ b/setup.py @@ -177,6 +177,19 @@ else: "python-ldap", ] +setup_requires=[ + "babel>=0.9.6", + "setuptools_scm", + "minify", +] +tests_require=[ + "mock>=1.3.0", + "coverage>=4.0.1", + "mockldap>=0.2.6", + "pytest<5.0.0", +] +extras_require={'tox': tests_require} + long_description_content_type = long_description = None with open(os.path.join(os.path.dirname(__file__), 'README.md')) as f: long_description = f.read() @@ -206,18 +219,10 @@ setup( }, install_requires=install_requires, # required packages for build process - setup_requires=[ - "babel>=0.9.6", - "minify", - "setuptools_scm", - ], + setup_requires=setup_requires, # requirement for testing - tests_require=[ - "mock>=1.3.0", - "coverage>=4.0.1", - "mockldap>=0.2.6", - "pytest<5.0.0", - ], + tests_require=tests_require, + extras_require=extras_require, classifiers=[ 'Development Status :: 5 - Production/Stable', 'Intended Audience :: System Administrators', diff --git a/tox.ini b/tox.ini index 46654722af12b0d7934c7b039b088f750a7caa8b..2745f314ba4115f1c1a6d9504e61bc9a7154da28 100644 --- a/tox.ini +++ b/tox.ini @@ -41,4 +41,5 @@ deps= cherrypy16: cherrypy>=16.0.0,<17.0.0 cherrypy17: cherrypy>=17.0.0,<18.0.0 cherrypy18: cherrypy>=18.0.0,<19.0.0 +commands_pre=pip install -e .[tox] commands=python setup.py nosetests --xunit-file=nosetests-{envname}.xml --xunit-testsuite-name={envname} --cover-xml-file=coverage-{envname}.xml