Commit 2b3ebf92 authored by szager@chromium.org's avatar szager@chromium.org

Fix error messages

BUG=
R=iannucci@chromium.org

Review URL: https://codereview.chromium.org/198723010

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@257541 0039d316-1c4b-4281-b951-d872f2087c98
parent 1520d908
......@@ -16,7 +16,8 @@ def native_error(msg, version):
print textwrap.dedent("""\
ERROR: Native python-coverage (version: %s) is required to be
installed on your PYTHONPATH to run this test. Recommendation:
sudo pip install python-coverage
sudo apt-get install pip
sudo pip install --upgrade coverage
%s""") % (version, msg)
sys.exit(1)
......@@ -35,7 +36,7 @@ def covered_main(includes, require_native=None):
import coverage
if require_native is not None:
got_ver = coverage.__version__
if not coverage.collector.CTracer:
if not getattr(coverage.collector, 'CTracer', None):
native_error((
"Native python-coverage module required.\n"
"Pure-python implementation (version: %s) found: %s"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment