From 16ad5c54468387d922c1f60cc134085a9f316f61 Mon Sep 17 00:00:00 2001 From: kumar Date: Fri, 18 Mar 2011 23:38:55 -0500 Subject: fixes addSkip for python 3.2 (issue 382); also adds 3.2 tests --- CHANGELOG | 6 +++++- nose/proxy.py | 3 +++ nosetests.1 | 2 +- tox.ini | 15 ++++++++++----- 4 files changed, 19 insertions(+), 7 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 08c5bb8..cf1ff91 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,4 +1,8 @@ -1.0 +1.0.1 + +- Fixed problems with SkipTest in Python 3.2 (#389) + +1.0.0 - Made nose compatible with python 3. **Huge** thanks to Alex "foogod" Stewart! diff --git a/nose/proxy.py b/nose/proxy.py index db21408..0d31d67 100644 --- a/nose/proxy.py +++ b/nose/proxy.py @@ -148,6 +148,9 @@ class ResultProxy(object): from nose.plugins.skip import SkipTest self.assertMyTest(test) plugins = self.plugins + if not isinstance(reason, Exception): + # for Python 3.2+ + reason = Exception(reason) plugins.addError(self.test, (SkipTest, reason, None)) self.result.addSkip(self.test, reason) diff --git a/nosetests.1 b/nosetests.1 index cde7b8f..e981883 100644 --- a/nosetests.1 +++ b/nosetests.1 @@ -466,5 +466,5 @@ jpellerin+nose@gmail.com .SH COPYRIGHT LGPL -.\" Generated by docutils manpage writer on 2011-02-01 13:49. +.\" Generated by docutils manpage writer on 2011-03-18 23:36. .\" diff --git a/tox.ini b/tox.ini index 0946208..e861153 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist=py31,py27,py26,py25,py24,jython,docs +envlist=py32,py31,py27,py26,py25,py24,jython,docs [testenv] deps= coverage >=3.3 @@ -25,8 +25,13 @@ commands= jython selftest.py [] [testenv:py31] -basepython=python3.1 -distribute=True commands= - python3.1 setup.py build_tests - python3.1 selftest.py [] + rm -fr {toxinidir}/build/tests + {envpython} setup.py build_tests + {envpython} selftest.py [] + +[testenv:py32] +commands= + rm -fr {toxinidir}/build/tests + {envpython} setup.py build_tests + {envpython} selftest.py [] -- cgit v1.2.1