forked from andri-ch/vimrunner-python
- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.py
More file actions
Latest commit
68 lines (59 loc) · 1.87 KB
/
Copy pathsetup.py
File metadata and controls
68 lines (59 loc) · 1.87 KB
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
#!/usr/bin/env python
# -*- Mode: Python; coding: utf-8; indent-tabs-mode: nil; tab-width: 4 -*-
importio
importsys
fromsetuptoolsimportsetup
#from distutils.core import setup
fromsetuptools.command.testimporttestasTestCommand
defread(*filenames, **kwargs):
encoding=kwargs.get('encoding', 'utf-8')
sep=kwargs.get('sep', '\n')
buf= []
forfilenameinfilenames:
withio.open(filename, encoding=encoding) asf:
buf.append(f.read())
returnsep.join(buf)
classPyTestCommand(TestCommand):
""" Command to run unit py.test unit tests
"""
deffinalize_options(self):
TestCommand.finalize_options(self)
self.test_args= ['test/tests.py']
self.test_suite=True
defrun(self):
importpytest
rcode=pytest.main(self.test_args)
sys.exit(rcode)
setup(
name='vimrunner',
version='1.0.3',
description='Interface for controlling a Vim editor using Python code.',
long_description=read('README.rst'),
author='Andrei Chiver',
author_email='andreichiver@gmail.com',
license='MIT',
url='https://github.com/andri-ch/vimrunner-python',
#provides=['vimrunner'],
#py_modules=['vimrunner'],
#package_dir=['vimrunner'],
packages=['vimrunner'],
package_data={'vimrunner': ['default_vimrc']},
#data_files=[('', ['default_vimrc'])],
classifiers=[
'Development Status :: 3 - Alpha',
'Topic :: Software Development',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'License :: OSI Approved :: MIT License',
],
keywords='test Vim editor server plugin',
tests_require=[
'pytest',
],
cmdclass={
'test': PyTestCommand,
# so you can do at the command line:
# python setup.py test
},
)