unittest: use unittest.mock instead of mock

because the absence of unittest.mock on python2.7, we still fallback to
mock
This commit is contained in:
Yuming Zhu 2024-10-18 13:05:09 +00:00
parent 589e6bbb96
commit ca05418fb5
390 changed files with 966 additions and 451 deletions

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,5 +1,5 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,5 +1,5 @@
import base64
import mock
from unittest import mock
import os
import unittest

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,5 +1,5 @@
import datetime
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,7 +1,7 @@
import unittest
import koji
import kojihub
import mock
from unittest import mock
class TestBuild(unittest.TestCase):

View file

@ -1,7 +1,7 @@
import unittest
import koji
import kojihub
import mock
from unittest import mock
class TestBuildImage(unittest.TestCase):

View file

@ -1,7 +1,7 @@
import unittest
import koji
import kojihub
import mock
from unittest import mock
class TestBuildImageIndirection(unittest.TestCase):

View file

@ -1,7 +1,7 @@
import unittest
import koji
import kojihub
import mock
from unittest import mock
class TestBuildImageOz(unittest.TestCase):

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import unittest

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
from kojihub import db

View file

@ -1,7 +1,7 @@
# coding: utf-8
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import os
import shutil
import tempfile

View file

@ -1,7 +1,7 @@
import unittest
import koji
import kojihub
import mock
from unittest import mock
class TestChainBuild(unittest.TestCase):

View file

@ -1,7 +1,7 @@
import unittest
import koji
import kojihub
import mock
from unittest import mock
class TestChainMaven(unittest.TestCase):

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji
import koji.policy

View file

@ -1,5 +1,5 @@
import copy
import mock
from unittest import mock
import os
import os.path
import shutil

View file

@ -1,5 +1,5 @@
import copy
import mock
from unittest import mock
import os
import os.path
import shutil

View file

@ -1,7 +1,7 @@
# coding: utf-8
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,7 +1,7 @@
# coding: utf-8
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,5 +1,5 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,5 +1,5 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,5 +1,5 @@
import unittest
import mock
from unittest import mock
import kojihub

View file

@ -1,7 +1,7 @@
# coding: utf-8
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import time
import unittest
from collections import defaultdict

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji

View file

@ -3,7 +3,7 @@ import tempfile
import shutil
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,5 +1,5 @@
import unittest
import mock
from unittest import mock
import os
import shutil
import tempfile

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,7 +1,7 @@
# coding: utf-8
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,7 +1,7 @@
# coding: utf-8
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import os
import os.path
import shutil

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
from .utils import DBQueryTestCase

View file

@ -1,7 +1,7 @@
import os.path
import shutil
import tempfile
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import os
import unittest
import koji

View file

@ -1,7 +1,7 @@
import os
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji
import kojihub.repos

View file

@ -1,5 +1,5 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,6 +1,6 @@
import koji
import kojihub
import mock
from unittest import mock
from .utils import DBQueryTestCase

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import os
import shutil
import tempfile

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub
from .utils import DBQueryTestCase

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import kojihub
from .utils import DBQueryTestCase

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import kojihub
from .utils import DBQueryTestCase

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub
from .utils import DBQueryTestCase

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub
from .utils import DBQueryTestCase

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub
from .utils import DBQueryTestCase

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,5 +1,5 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import koji
import kojihub
import mock
from unittest import mock
from .utils import DBQueryTestCase

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import kojihub
from .utils import DBQueryTestCase

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,5 +1,5 @@
import os
import mock
from unittest import mock
import shutil
import tempfile
import unittest

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import unittest
import koji
from .utils import DBQueryTestCase

View file

@ -1,5 +1,5 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,4 +1,4 @@
import mock
from unittest import mock
import koji
import kojihub
from .utils import DBQueryTestCase

View file

@ -1,6 +1,6 @@
# coding: utf-8
import unittest
import mock
from unittest import mock
import koji
import kojihub

View file

@ -1,6 +1,6 @@
import unittest
import mock
from unittest import mock
import koji
import kojihub

Some files were not shown because too many files have changed in this diff Show more