aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2014-03-16 05:33:24 -0400
committerJason R. Coombs <jaraco@jaraco.com>2014-03-16 05:33:24 -0400
commitcdbcb2b5ea59a09ab16a3f024c27f4ce6553ddff (patch)
tree69a8d0bc2dcb0a604154a33fc01d1b2859de3b5e
parentddce1ca3b19ac6fa504a996ca6d652681503381a (diff)
downloadexternal_python_setuptools-cdbcb2b5ea59a09ab16a3f024c27f4ce6553ddff.tar.gz
external_python_setuptools-cdbcb2b5ea59a09ab16a3f024c27f4ce6553ddff.tar.bz2
external_python_setuptools-cdbcb2b5ea59a09ab16a3f024c27f4ce6553ddff.zip
Use py26compat for skipIf
-rw-r--r--setuptools/tests/test_find_packages.py13
1 files changed, 7 insertions, 6 deletions
diff --git a/setuptools/tests/test_find_packages.py b/setuptools/tests/test_find_packages.py
index abb0dd61..bc7d03bf 100644
--- a/setuptools/tests/test_find_packages.py
+++ b/setuptools/tests/test_find_packages.py
@@ -6,6 +6,7 @@ import tempfile
import unittest
from setuptools import find_packages
+from setuptools.tests.py26compat import skipIf
PEP420 = sys.version_info[:2] >= (3, 3)
@@ -62,7 +63,7 @@ class TestFindPackages(unittest.TestCase):
fp.close()
return path
- @unittest.skipIf(PEP420, 'Not a PEP 420 env')
+ @skipIf(PEP420, 'Not a PEP 420 env')
def test_regular_package(self):
self._touch('__init__.py', self.pkg_dir)
packages = find_packages(self.dist_dir)
@@ -86,33 +87,33 @@ class TestFindPackages(unittest.TestCase):
packages = find_packages(self.dist_dir)
self.assertTrue('pkg.some.data' not in packages)
- @unittest.skipIf(not PEP420, 'PEP 420 only')
+ @skipIf(not PEP420, 'PEP 420 only')
def test_pep420_ns_package(self):
packages = find_packages(
self.dist_dir, include=['pkg*'], exclude=['pkg.subpkg.assets'])
self.assertEqual(packages, ['pkg', 'pkg.nspkg', 'pkg.subpkg'])
- @unittest.skipIf(not PEP420, 'PEP 420 only')
+ @skipIf(not PEP420, 'PEP 420 only')
def test_pep420_ns_package_no_includes(self):
packages = find_packages(
self.dist_dir, exclude=['pkg.subpkg.assets'])
self.assertEqual(packages, ['docs', 'pkg', 'pkg.nspkg', 'pkg.subpkg'])
- @unittest.skipIf(not PEP420, 'PEP 420 only')
+ @skipIf(not PEP420, 'PEP 420 only')
def test_pep420_ns_package_no_includes_or_excludes(self):
packages = find_packages(self.dist_dir)
expected = [
'docs', 'pkg', 'pkg.nspkg', 'pkg.subpkg', 'pkg.subpkg.assets']
self.assertEqual(packages, expected)
- @unittest.skipIf(not PEP420, 'PEP 420 only')
+ @skipIf(not PEP420, 'PEP 420 only')
def test_regular_package_with_nested_pep420_ns_packages(self):
self._touch('__init__.py', self.pkg_dir)
packages = find_packages(
self.dist_dir, exclude=['docs', 'pkg.subpkg.assets'])
self.assertEqual(packages, ['pkg', 'pkg.nspkg', 'pkg.subpkg'])
- @unittest.skipIf(not PEP420, 'PEP 420 only')
+ @skipIf(not PEP420, 'PEP 420 only')
def test_pep420_ns_package_no_non_package_dirs(self):
shutil.rmtree(self.docs_dir)
shutil.rmtree(os.path.join(self.dist_dir, 'pkg/subpkg/assets'))