diff --git a/setup.py b/setup.py index f2dae127..a28bc46c 100755 --- a/setup.py +++ b/setup.py @@ -66,5 +66,5 @@ setup( "dogpile.cache", ], extras_require={':python_version=="2.7"': ["enum34", "lockfile"]}, - tests_require=["mock", "pytest", "pytest-cov", "pyfakefs"], + tests_require=["pytest", "pytest-cov", "pyfakefs"], ) diff --git a/test-requirements.txt b/test-requirements.txt index 475f0328..2d921c76 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -1,4 +1,4 @@ -mock +mock; python_version < '3.3' parameterized pytest pytest-cov diff --git a/tests/test_pkgset_pkgsets.py b/tests/test_pkgset_pkgsets.py index 2fc81da6..aed56126 100644 --- a/tests/test_pkgset_pkgsets.py +++ b/tests/test_pkgset_pkgsets.py @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- + import ddt from unittest import mock import os diff --git a/tests/test_pkgset_source_koji.py b/tests/test_pkgset_source_koji.py index b270bd52..385db314 100644 --- a/tests/test_pkgset_source_koji.py +++ b/tests/test_pkgset_source_koji.py @@ -1,7 +1,8 @@ # -*- coding: utf-8 -*- import json - +import unittest +from unittest import mock import os import re import six @@ -10,13 +11,6 @@ from typing import AnyStr, List, Set, Dict, Tuple from tests.test_gather_method_hybrid import MockModule -try: - import unittest2 as unittest - from unittest2 import mock -except ImportError: - import unittest - from unittest import mock - from pungi.phases.pkgset.sources import source_koji, source_kojimock from tests import helpers from pungi.module_util import Modulemd