summaryrefslogtreecommitdiff
path: root/setup.py
diff options
context:
space:
mode:
authorIan Cordasco <graffatcolmingov@gmail.com>2016-01-10 12:01:22 -0600
committerIan Cordasco <graffatcolmingov@gmail.com>2016-01-10 12:01:22 -0600
commit6553198074593841d720c9978103fb0d5f6e6915 (patch)
treec2d2d3a0413fc361194d3d55d923f7ef158fcac5 /setup.py
parentde96b24bad8a1b099749a8b8473de9e885b4718e (diff)
downloadflake8-6553198074593841d720c9978103fb0d5f6e6915.tar.gz
Update setup.py
Diffstat (limited to 'setup.py')
-rw-r--r--setup.py20
1 files changed, 8 insertions, 12 deletions
diff --git a/setup.py b/setup.py
index d0650f4..92ea08f 100644
--- a/setup.py
+++ b/setup.py
@@ -1,6 +1,9 @@
# -*- coding: utf-8 -*-
from __future__ import with_statement
-from setuptools import setup
+import setuptools
+
+import flake8
+
try:
# Work around a traceback with Nose on Python 2.6
# http://bugs.python.org/issue15881#msg170215
@@ -16,18 +19,11 @@ except ImportError:
mock = None
-tests_require = ['nose']
+tests_require = ['pytest']
if mock is None:
tests_require += ['mock']
-def get_version(fname='flake8/__init__.py'):
- with open(fname) as f:
- for line in f:
- if line.startswith('__version__'):
- return eval(line.split('=')[-1])
-
-
def get_long_description():
descr = []
for fname in ('README.rst', 'CHANGES.rst'):
@@ -36,10 +32,10 @@ def get_long_description():
return '\n\n'.join(descr)
-setup(
+setuptools.setup(
name="flake8",
license="MIT",
- version=get_version(),
+ version=flake8.__version__,
description="the modular source code checker: pep8, pyflakes and co",
# long_description=get_long_description(),
author="Tarek Ziade",
@@ -71,5 +67,5 @@ setup(
"Topic :: Software Development :: Quality Assurance",
],
tests_require=tests_require,
- test_suite='nose.collector',
+ setup_requires=['pytest-runner'],
)