Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(395)

Unified Diff: scripts/slave/unittests/expect_tests/cover.py

Issue 225633007: Upgrade to coverage 3.7.1 and have it auto-build itself on first use. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/build
Patch Set: sigh our imports are a mess Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « scripts/slave/unittests/__init__.py ('k') | scripts/slave/unittests/recipe_configs_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scripts/slave/unittests/expect_tests/cover.py
diff --git a/scripts/slave/unittests/expect_tests/cover.py b/scripts/slave/unittests/expect_tests/cover.py
index 21f717e170e20e2668f24e5d9480f63868bb9fce..7fdbf92d5f379def6a8c40cb64d866fed7b2c11f 100644
--- a/scripts/slave/unittests/expect_tests/cover.py
+++ b/scripts/slave/unittests/expect_tests/cover.py
@@ -4,23 +4,9 @@
from cStringIO import StringIO
-try:
- import coverage
- coverage_version = coverage.__version__
-except ImportError:
- coverage = None
- coverage_version = None
-
-from distutils.version import StrictVersion
-
-if (not coverage or
- not hasattr(coverage.collector, 'CTracer') or
- not coverage.collector.CTracer or
- StrictVersion(coverage_version) < StrictVersion('3.7')):
- raise ImportError(
- 'This test requires natively-installed python-coverage (>=3.7). '
- 'Current is %s.' % coverage_version)
+import test_env # pylint: disable=W0611
+import coverage
# This is instead of a contextmanager because it causes old pylints to crash :(
class _Cover(object):
« no previous file with comments | « scripts/slave/unittests/__init__.py ('k') | scripts/slave/unittests/recipe_configs_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698