-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.py
44 lines (40 loc) · 1.59 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
from __future__ import print_function
from setuptools import setup, Command
# run our tests
class PyTest(Command):
user_options = []
def initialize_options(self):
pass
def finalize_options(self):
pass
def run(self):
import sys, subprocess
tests = [('test suite', ['-m', 'test.test_namedlist']),
('doctests', ['-m' 'doctest', 'README.txt']),
]
for name, cmds in tests:
print(name)
errno = subprocess.call([sys.executable] + cmds)
if errno != 0:
raise SystemExit(errno)
print('test complete')
setup(name='namedlist',
version='1.8',
url='https://gitlab.com/ericvsmith/namedlist',
author='Eric V. Smith',
author_email='[email protected]',
description='Similar to namedtuple, but instances are mutable.',
long_description=open('README.txt').read() + '\n' + open('CHANGES.txt').read(),
classifiers=['Development Status :: 5 - Production/Stable',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License',
'Topic :: Software Development :: Libraries :: Python Modules',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
],
license='Apache License Version 2.0',
py_modules=['namedlist'],
cmdclass = {'test': PyTest},
)