Leverage on pbr (Python Build Reasonableness) 09/40609/1
authorCédric Ollivier <cedric.ollivier@orange.com>
Tue, 29 Aug 2017 19:21:02 +0000 (21:21 +0200)
committerCédric Ollivier <cedric.ollivier@orange.com>
Tue, 29 Aug 2017 19:24:31 +0000 (21:24 +0200)
It also removes the exec right on mce-inject_ea and installs it in
$PATH. requirements.txt is also created to install the abstract
dependencies.

Change-Id: I176df99d2f40e1910079f5efa3f28a8c170a922d
Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
.gitignore
baro_tests/mce-inject_ea [changed mode: 0755->0644]
requirements.txt [new file with mode: 0644]
setup.cfg [new file with mode: 0644]
setup.py

index 07fdf03..292d8c3 100644 (file)
@@ -4,3 +4,8 @@
 /docs_build/
 /docs_output/
 /releng/
+*.egg-info/
+.*project
+.settings
+build
+dist
old mode 100755 (executable)
new mode 100644 (file)
diff --git a/requirements.txt b/requirements.txt
new file mode 100644 (file)
index 0000000..a5af657
--- /dev/null
@@ -0,0 +1,5 @@
+paramiko>=2.0 # LGPLv2.1+
+requests!=2.12.2,>=2.10.0 # Apache-2.0
+python-keystoneclient>=3.8.0 # Apache-2.0
+opnfv
+functest
diff --git a/setup.cfg b/setup.cfg
new file mode 100644 (file)
index 0000000..3604adb
--- /dev/null
+++ b/setup.cfg
@@ -0,0 +1,9 @@
+[metadata]
+name = baro_tests
+version = 5
+home-page = https://wiki.opnfv.org/display/fastpath/Barometer+Home
+
+[files]
+packages = baro_tests
+scripts =
+    baro_tests/mce-inject_ea
index 8d37048..a1e9b3b 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -1,18 +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
-##############################################################################
-
 
-from setuptools import setup, find_packages
+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
 
-setup(
-    name="baro_tests",
-    version="danube",
-    packages=find_packages(),
-    include_package_data=True,
-    package_data={},
-    url="https://www.opnfv.org")
+setuptools.setup(
+    setup_requires=['pbr>=1.8'],
+    pbr=True)