Skip to content

Commit

Permalink
depend on setuptools and run tests via setup.py
Browse files Browse the repository at this point in the history
  • Loading branch information
cgoldberg committed Sep 30, 2017
1 parent 4b6789f commit 07fc271
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 13 deletions.
19 changes: 8 additions & 11 deletions setup.py
Expand Up @@ -5,24 +5,21 @@


import os

try:
from setuptools import setup
except ImportError:
from distutils.core import setup
import setuptools
import sys


this_dir = os.path.abspath(os.path.dirname(__file__))
with open(os.path.join(this_dir, 'README.rst')) as f:
LONG_DESCRIPTION = '\n' + f.read()

tests_require = []
try:
from unittest import mock # noqa
except ImportError:
tests_require.append('mock')
if sys.version_info.major < 3:
tests_require = ['mock']
else:
tests_require = []


setup(
setuptools.setup(
name='xvfbwrapper',
version='0.2.10dev',
py_modules=['xvfbwrapper'],
Expand Down
3 changes: 1 addition & 2 deletions tox.ini
Expand Up @@ -7,8 +7,7 @@
envlist = flake8,py27,py33,py34,py35,pypy

[testenv]
commands = {envpython} -m unittest discover
deps = py27,pypy: mock
commands = {envpython} setup.py test

[testenv:flake8]
deps = flake8
Expand Down

0 comments on commit 07fc271

Please sign in to comment.