forked from acroz/pylivy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
69 lines (56 loc) · 1.43 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
import sys
from pathlib import Path
from setuptools import setup
from setuptools.command.test import test as TestCommand
README = Path(__file__).parent / 'README.rst'
class PyTest(TestCommand):
user_options = [
('addopts=', None, 'Additional options to be passed verbatim to the '
'pytest runner')
]
fixed_arguments = ''
def initialize_options(self):
super().initialize_options()
self.addopts = ''
def run_tests(self):
import shlex
import pytest
errno = pytest.main(
shlex.split(self.addopts + ' ' + self.fixed_arguments)
)
sys.exit(errno)
class UnitTests(PyTest):
fixed_arguments = 'tests'
class IntegrationTests(PyTest):
fixed_arguments = 'it'
setup(
name='livy',
version='0.3.1',
description='A Python client for Apache Livy',
long_description=README.read_text(),
packages=['livy'],
url='https://github.com/acroz/pylivy',
author='Andrew Crozier',
author_email='wacrozier@gmail.com',
license='MIT',
classifiers=[
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
],
setup_requires=[
'wheel'
],
cmdclass={
'test': UnitTests,
'it': IntegrationTests
},
install_requires=[
'requests',
'pandas'
],
tests_require=[
'pytest',
'pytest-mock',
'flask'
]
)