Skip to content
Browse files

provide a tox.ini for easier testing; cope with setup.py stupidity in…

… generating long_description
  • Loading branch information...
1 parent 104e391 commit ab74f9d6253f630e5c658839425b9d9a916a014d @mcdonc mcdonc committed Jul 22, 2011
Showing with 39 additions and 2 deletions.
  1. +1 −0 .gitignore
  2. +6 −2 setup.py
  3. +32 −0 tox.ini
View
1 .gitignore
@@ -4,3 +4,4 @@ docs/_build
*.egg-info
env26/
dist/
+.tox
View
8 setup.py
@@ -18,8 +18,12 @@
from setuptools import setup, find_packages
here = os.path.abspath(os.path.dirname(__file__))
-README = open(os.path.join(here, 'README.txt')).read()
-CHANGES = open(os.path.join(here, 'CHANGES.txt')).read()
+try:
+ README = open(os.path.join(here, 'README.txt')).read()
+ CHANGES = open(os.path.join(here, 'CHANGES.txt')).read()
+except IOError:
+ README = ''
+ CHANGES = ''
setup(name='pyramid_who',
version=__version__,
View
32 tox.ini
@@ -0,0 +1,32 @@
+[tox]
+envlist =
+ py25,py26,py27,jython,pypy,cover
+
+[testenv]
+commands =
+ python setup.py test -q
+deps =
+ pyramid
+ repoze.who
+
+[testenv:jython]
+commands =
+ jython setup.py test -q
+
+[testenv:cover]
+basepython =
+ python2.6
+commands =
+ python setup.py nosetests --with-xunit --with-xcoverage
+deps =
+ pyramid
+ repoze.who
+ nose
+ coverage==3.4
+ nosexcover
+
+# we separate coverage into its own testenv because a) "last run wins" wrt
+# cobertura jenkins reporting and b) pypy and jython can't handle any
+# combination of versions of coverage and nosexcover that i can find.
+# coverage==3.4 is required by nosexcover.
+

0 comments on commit ab74f9d

Please sign in to comment.
Something went wrong with that request. Please try again.