From 18be5708eb91ac1bbd6fef713233c68857e34694 Mon Sep 17 00:00:00 2001 From: Hugo Date: Tue, 19 Jun 2018 07:27:00 -0400 Subject: Drop support for EOL 2.5, 2.6 and 3.3 --- __main__.py | 11 ++--------- doc/contributing.rst | 2 +- tests/test_process.py | 3 --- 3 files changed, 3 insertions(+), 13 deletions(-) diff --git a/__main__.py b/__main__.py index c998e1d..f1f2b4f 100644 --- a/__main__.py +++ b/__main__.py @@ -8,12 +8,5 @@ import os PKG = 'coverage' -try: - run_globals = runpy.run_module(PKG, run_name='__main__', alter_sys=True) - executed = os.path.splitext(os.path.basename(run_globals['__file__']))[0] - if executed != '__main__': # For Python 2.5 compatibility - raise ImportError( - 'Incorrectly executed %s instead of __main__' % executed - ) -except ImportError: # For Python 2.6 compatibility - runpy.run_module('%s.__main__' % PKG, run_name='__main__', alter_sys=True) +run_globals = runpy.run_module(PKG, run_name='__main__', alter_sys=True) +executed = os.path.splitext(os.path.basename(run_globals['__file__']))[0] diff --git a/doc/contributing.rst b/doc/contributing.rst index 656d251..896b39c 100644 --- a/doc/contributing.rst +++ b/doc/contributing.rst @@ -117,7 +117,7 @@ the second uses the C implementation. To limit tox to just a few versions of Python, use the ``-e`` switch:: - $ tox -e py27,py33 + $ tox -e py27,py37 To run just a few tests, you can use `pytest test selectors`_:: diff --git a/tests/test_process.py b/tests/test_process.py index 7e55c77..68262a5 100644 --- a/tests/test_process.py +++ b/tests/test_process.py @@ -659,9 +659,6 @@ class ProcessTest(CoverageTest): self.assertGreater(data.line_counts()['os.py'], 50) def test_lang_c(self): - if env.PY3 and env.PYVERSION < (3, 4): - # Python 3.3 can't compile the non-ascii characters in the file name. - self.skipTest("3.3 can't handle this test") if env.JYTHON: # Jython as of 2.7.1rc3 won't compile a filename that isn't utf8. self.skipTest("Jython can't handle this test") -- cgit v1.2.1