Mercurial > hgsubversion
changeset 734:e24fb3e27ec9
test_util: use SkipTest if provided by the unittest module.
This is the case with Python 2.7.
author | Dan Villiom Podlaski Christiansen <danchr@gmail.com> |
---|---|
date | Sat, 09 Oct 2010 16:20:52 -0500 |
parents | bfb88a304ebe |
children | c2b9e08ecf10 |
files | tests/test_util.py |
diffstat | 1 files changed, 7 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/test_util.py +++ b/tests/test_util.py @@ -26,12 +26,15 @@ from mercurial import ui from mercurial import extensions try: - from unittest2 import SkipTest -except ImportError: + SkipTest = unittest.SkipTest +except AttributeError: try: - from nose import SkipTest + from unittest2 import SkipTest except ImportError: - SkipTest = None + try: + from nose import SkipTest + except ImportError: + SkipTest = None from hgsubversion import util