summaryrefslogtreecommitdiffstats
path: root/Lib/packaging/tests/test_util.py
diff options
context:
space:
mode:
authorÉric Araujo <merwok@netwok.org>2011-09-17 01:31:51 (GMT)
committerÉric Araujo <merwok@netwok.org>2011-09-17 01:31:51 (GMT)
commit7724a6c10c56a1b14b4933de368e672eae840f47 (patch)
tree1b3bd60ab9b79bd018cbc942a8e12140b2e18576 /Lib/packaging/tests/test_util.py
parent37ccd6f794539e0678b7a7ad938e571cc73e106c (diff)
downloadcpython-7724a6c10c56a1b14b4933de368e672eae840f47.zip
cpython-7724a6c10c56a1b14b4933de368e672eae840f47.tar.gz
cpython-7724a6c10c56a1b14b4933de368e672eae840f47.tar.bz2
Packaging cleanup: remove conditionals for < 2.6 support.
PEP 370 features and sys.dont_write_bytecode are always available in 3.3; the distutils2 backport still has the conditionals. I also renamed an internal misnamed method and fixed a few things (“packaging2” name, stray print, unused import, fd leak).
Diffstat (limited to 'Lib/packaging/tests/test_util.py')
-rw-r--r--Lib/packaging/tests/test_util.py4
1 files changed, 0 insertions, 4 deletions
diff --git a/Lib/packaging/tests/test_util.py b/Lib/packaging/tests/test_util.py
index c3d91aa..2872458 100644
--- a/Lib/packaging/tests/test_util.py
+++ b/Lib/packaging/tests/test_util.py
@@ -319,8 +319,6 @@ class UtilTestCase(support.EnvironRestorer,
res = get_compiler_versions()
self.assertEqual(res[2], None)
- @unittest.skipUnless(hasattr(sys, 'dont_write_bytecode'),
- 'sys.dont_write_bytecode not supported')
def test_dont_write_bytecode(self):
# makes sure byte_compile raise a PackagingError
# if sys.dont_write_bytecode is True
@@ -407,7 +405,6 @@ class UtilTestCase(support.EnvironRestorer,
finally:
sys.path.remove(tmp_dir)
- @unittest.skipIf(sys.version < '2.6', 'requires Python 2.6 or higher')
def test_run_2to3_on_code(self):
content = "print 'test'"
converted_content = "print('test')"
@@ -422,7 +419,6 @@ class UtilTestCase(support.EnvironRestorer,
file_handle.close()
self.assertEqual(new_content, converted_content)
- @unittest.skipIf(sys.version < '2.6', 'requires Python 2.6 or higher')
def test_run_2to3_on_doctests(self):
# to check if text files containing doctests only get converted.
content = ">>> print 'test'\ntest\n"