summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomi Juvonen <tomi.juvonen@nokia.com>2017-09-05 12:07:27 +0000
committerGerrit Code Review <gerrit@opnfv.org>2017-09-05 12:07:27 +0000
commit7cbdc3b64449c729c39dd33e1785076b8a127d68 (patch)
tree7577633af85bddabc17e965633a556dcdb4b6f9a
parent1c1d3d1ddc21ae28deabef9f5f6e310d46fdf0ef (diff)
parent9ee9b136ebec5d21f5165acc5e4441c3e91a56dd (diff)
Merge "Add doctor-test package"
-rw-r--r--.gitignore3
-rw-r--r--requirements.txt14
-rw-r--r--setup.cfg13
-rw-r--r--setup.py22
-rw-r--r--test-requirements.txt14
-rw-r--r--tests/__init__.py0
-rw-r--r--tests/main.py4
-rw-r--r--tox.ini10
8 files changed, 58 insertions, 22 deletions
diff --git a/.gitignore b/.gitignore
index c671eeed..7e893869 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,6 +2,9 @@
*.pyc
.*.sw?
**.log
+*.pyc
+/*.egg-info/
+/build/
/docs_build/
/docs_output/
/releng/
diff --git a/requirements.txt b/requirements.txt
new file mode 100644
index 00000000..4623289d
--- /dev/null
+++ b/requirements.txt
@@ -0,0 +1,14 @@
+Flask!=0.11,<1.0,>=0.10 # BSD
+paramiko>=2.0 # LGPLv2.1+
+scp
+requests!=2.12.2,>=2.10.0 # Apache-2.0
+oslo.config!=3.18.0,>=3.14.0 # Apache-2.0
+python-openstackclient>=3.3.0 # Apache-2.0
+python-ceilometerclient>=2.5.0 # Apache-2.0
+aodhclient>=0.7.0 # Apache-2.0
+python-keystoneclient>=3.8.0 # Apache-2.0
+python-neutronclient>=5.1.0 # Apache-2.0
+python-novaclient!=7.0.0,>=6.0.0 # Apache-2.0
+python-congressclient<2000,>=1.3.0 # Apache-2.0
+python-glanceclient>=2.5.0 # Apache-2.0
+virtualenv>=13.1.0 # MIT
diff --git a/setup.cfg b/setup.cfg
new file mode 100644
index 00000000..d294cf38
--- /dev/null
+++ b/setup.cfg
@@ -0,0 +1,13 @@
+[metadata]
+name = doctor-test
+version = 2017.9.0
+home-page = https://wiki.opnfv.org/display/doctor/Doctor+Home
+
+[files]
+packages = tests
+scripts =
+ tests/run.sh
+
+[entry_points]
+console_scripts =
+ doctor-test = tests.main:main
diff --git a/setup.py b/setup.py
new file mode 100644
index 00000000..a1e9b3bb
--- /dev/null
+++ b/setup.py
@@ -0,0 +1,22 @@
+#!/usr/bin/env python
+
+# Copyright (c) 2017 Orange and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+
+import setuptools
+
+# In python < 2.7.4, a lazy loading of package `pbr` will break
+# setuptools if some other modules registered functions in `atexit`.
+# solution from: http://bugs.python.org/issue15881#msg170215
+try:
+ import multiprocessing # noqa
+except ImportError:
+ pass
+
+setuptools.setup(
+ setup_requires=['pbr>=1.8'],
+ pbr=True)
diff --git a/test-requirements.txt b/test-requirements.txt
deleted file mode 100644
index 070caa44..00000000
--- a/test-requirements.txt
+++ /dev/null
@@ -1,14 +0,0 @@
-Flask==0.10.1
-paramiko==1.16.0
-scp==0.10.2
-requests>=2.8.0
-oslo.config==3.22.0 # Apache-2.0
-python-openstackclient==2.3.0
-python-ceilometerclient==2.6.2
-aodhclient==0.7.0
-python-keystoneclient==3.5.0
-python-neutronclient==6.0.0
-python-novaclient==6.0.0
-python-congressclient==1.5.0
-python-glanceclient==2.5.0
-virtualenv==15.1.0
diff --git a/tests/__init__.py b/tests/__init__.py
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/tests/__init__.py
diff --git a/tests/main.py b/tests/main.py
index df7e95f3..edff16f2 100644
--- a/tests/main.py
+++ b/tests/main.py
@@ -211,7 +211,3 @@ def main():
doctor = DoctorTest(conf)
doctor.run()
-
-
-if __name__ == '__main__':
- sys.exit(main())
diff --git a/tox.ini b/tox.ini
index d4babeb8..c8cebe8b 100644
--- a/tox.ini
+++ b/tox.ini
@@ -4,9 +4,12 @@ envlist = py34
skipsdist = True
[testenv]
-install_command = pip install -U {opts} {packages}
+usedevelop = True
+install_command = pip install \
+ -chttps://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt?h=stable/ocata \
+ {opts} {packages}
setenv = VIRTUAL_ENV={envdir}
-deps = -r{toxinidir}/test-requirements.txt
+deps = -r{toxinidir}/requirements.txt
passenv =
OS_AUTH_URL
OS_USERNAME
@@ -24,5 +27,4 @@ passenv =
INSTALLER_IP
PROFILER_TYPE
changedir = {toxinidir}/tests
-commands = python main.py
-
+commands = doctor-test