Merge "tox support"

This commit is contained in:
Jenkins 2016-06-08 09:16:56 +00:00 committed by Gerrit Code Review
commit 93319543bc
5 changed files with 102 additions and 23 deletions

10
requirements.txt Normal file
View File

@ -0,0 +1,10 @@
docopt
findspark
libpgm
numpy
schema
scipy
tornado
sklearn
kafka-python
pyparsing

40
setup.cfg Normal file
View File

@ -0,0 +1,40 @@
[metadata]
name = monanas
#name = monasca-analytics
summary = Monanas - Monasca Analytics
description-file =
README.md
author = OpenStack
author-email = openstack-dev@lists.openstack.org
home-page = https://launchpad.net/monasca
classifier =
Environment :: OpenStack
Intended Audience :: Information Technology
Intended Audience :: System Administrators
License :: OSI Approved :: Apache Software License
Operating System :: POSIX :: Linux
Programming Language :: Python
Programming Language :: Python :: 2
Programming Language :: Python :: 2.7
[files]
packages =
monasca_analytics
test
#data_files =
# etc/monasca =
# etc/monasca/analytics-config.conf
# etc/monasca/analytics-config.ini
[entry_points]
#console_scripts =
# monasca-analytics = monasca_analytics.server:launch
#
#tempest.test_plugins =
# monasca_analytics_tests = monasca_analytics_tests.plugin:MonascaAnalyticsTempestPlugin
[pbr]
warnerrors = True

View File

@ -18,28 +18,9 @@
Monanas setup script.
"""
import setuptools
from setuptools import setup
import setup_property
setuptools.setup(
name="monanas",
version=setup_property.VERSION,
description="Monanas - Monasca Analytics, ",
author="Actionable Insights, Manageability Group, "
"Security and Manageability Lab, Hewlett Packard Enterprise",
author_email="suksant.sae-lor@hpe.com, david.perez5@hpe.com, "
"luis.vaquero@hpe.com, joan.varvenne@hpe.com",
install_requires=[
"docopt",
"findspark",
"libpgm",
"numpy",
"schema",
"scipy",
"tornado",
"sklearn",
"kafka-python",
"pyparsing"
]
setup(
setup_requires=['pbr>=1.8'],
pbr=True,
)

5
test-requirements.txt Normal file
View File

@ -0,0 +1,5 @@
# mock object framework
hacking>=0.10.2
flake8>=2.2.4
nose==1.3.0
mock>=1.0.1

43
tox.ini Normal file
View File

@ -0,0 +1,43 @@
[tox]
minversion = 2.0
skipsdist = True
envlist = py27,pep8
[testenv]
usedevelop = True
setenv =
PYTHONUNBUFFERED=1
VIRTUAL_ENV={envdir}
DISCOVER_DIRECTORY=tests
PYTHONPATH=/home/vagrant/spark/python:/home/vagrant/spark/python/lib/py4j-0.9-src.zip:
install_command = pip install -U {opts} {packages}
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
whitelist_externals = bash
find
commands =
find ./ -type f -name "*.pyc" -delete
nosetests -w test
[testenv:cover]
[testenv:pep8]
commands =
flake8 monasca_analytics test
[testenv:genconfig]
[testenv:docs]
[testenv:venv]
install_command = pip install -U {opts} {packages}
commands = {posargs}
[flake8]
ignore = F821,H201,H302,H404,H405
max-complexity = 50
builtins = _
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,tools,build
show-source = True
[hacking]