From 0661e0e3eb6a4b328c6f5c2ff62159c9628d98ac Mon Sep 17 00:00:00 2001 From: Mike McLean Date: Thu, 18 May 2017 14:54:41 -0400 Subject: [PATCH] Work around coverage bug in py3 on Fedora --- Makefile | 2 -- koji/__init__.py | 1 + tests/test_lib/test_profiles.py | 4 +++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index e8062bbe..221d0e51 100644 --- a/Makefile +++ b/Makefile @@ -74,8 +74,6 @@ test3: coverage erase PYTHONPATH=hub/.:plugins/hub/.:plugins/builder/. nosetests-3 \ --with-coverage --cover-package . tests/test_lib tests/test_cli - @echo Sleeping to work around an issue - sleep 10 coverage html @echo Coverage report in htmlcov/index.html diff --git a/koji/__init__.py b/koji/__init__.py index 3b5c56e3..9e1e5ceb 100644 --- a/koji/__init__.py +++ b/koji/__init__.py @@ -21,6 +21,7 @@ # Mike McLean # Mike Bonnet + from __future__ import absolute_import import sys from six.moves import range diff --git a/tests/test_lib/test_profiles.py b/tests/test_lib/test_profiles.py index 3903db1e..04170232 100644 --- a/tests/test_lib/test_profiles.py +++ b/tests/test_lib/test_profiles.py @@ -6,8 +6,10 @@ import sys import threading import traceback from six.moves import range +import six - +# XXX remove skip when Fedora bug is fixed +@unittest.skipIf(six.PY3, "coverage bug Fedora, see rhbz#1452339") class ProfilesTestCase(unittest.TestCase): def test_profile_threading(self):