Separate test modules from requirements.txt 07/23507/1
authorVictor Morales <victor.morales@intel.com>
Tue, 14 Nov 2017 20:24:57 +0000 (12:24 -0800)
committerVictor Morales <victor.morales@intel.com>
Tue, 14 Nov 2017 20:24:57 +0000 (12:24 -0800)
The modules required for unit tests can be included in another file,
this helps during the packaging process to avoid the addition of
non-required dependencies.

Change-Id: I3d1dc0c265a26e22be66d261f2de2ae939a1d6f8
Signed-off-by: Victor Morales <victor.morales@intel.com>
Issue-Id: MULTICLOUD-83

newton/requirements.txt
newton/test-requirements.txt [new file with mode: 0644]
newton/tox.ini

index 841fe27..13ced9e 100644 (file)
@@ -1,17 +1,12 @@
 # rest framework
-Django==1.9.6
-djangorestframework==3.3.3
+Django==1.9.6  # BSD
+djangorestframework==3.3.3 # BSD
 
 # for call rest api
-httplib2==0.9.2
+httplib2==0.9.2 # MIT
 
 # for call openstack auth and transport api
-keystoneauth1==2.18.0
+keystoneauth1==2.19.0 # Apache-2.0
 
-#python-memcached
-python-memcached
-
-# for unit test
-coverage==4.2
-mock==2.0.0
-unittest_xml_reporting==1.12.0
+# for memcached
+python-memcached # PSF
diff --git a/newton/test-requirements.txt b/newton/test-requirements.txt
new file mode 100644 (file)
index 0000000..91213a4
--- /dev/null
@@ -0,0 +1,3 @@
+coverage==4.2 # Apache-2.0
+mock==2.0.0 # BSD
+unittest_xml_reporting==1.12.0 #BSD
index 71a8ff7..d5eb878 100644 (file)
@@ -6,7 +6,13 @@ skipsdist = true
 downloadcache = ~/cache/pip
 
 [testenv]
-deps = -r{toxinidir}/requirements.txt
+passenv = http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY
+deps =
+    -r{toxinidir}/requirements.txt
+    -r{toxinidir}/test-requirements.txt
 commands =
   coverage run --branch manage.py test
+
+[testenv:cover]
+commands =
   coverage report --omit=".tox/*,*tests*,*__init__.py" --fail-under=30