Use unittest.mock instead of third party mock

Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.

Change-Id: I72c472e13b4fc96aa81a1cab4a9f30c3df118107
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
changes/02/721002/1
Sean McGinnis 3 years ago
parent 3042a3cac8
commit 507d1c61e3
No known key found for this signature in database
GPG Key ID: CE7EE4BFAF8D70C8
  1. 3
      config_tempest/tests/base.py
  2. 2
      config_tempest/tests/services/test_aws.py
  3. 2
      config_tempest/tests/services/test_base.py
  4. 2
      config_tempest/tests/services/test_compute.py
  5. 2
      config_tempest/tests/services/test_horizon.py
  6. 3
      config_tempest/tests/services/test_identity.py
  7. 3
      config_tempest/tests/services/test_image.py
  8. 2
      config_tempest/tests/services/test_network.py
  9. 2
      config_tempest/tests/services/test_object_storage.py
  10. 2
      config_tempest/tests/services/test_services.py
  11. 2
      config_tempest/tests/services/test_volume.py
  12. 2
      config_tempest/tests/test_accounts.py
  13. 3
      config_tempest/tests/test_clients.py
  14. 3
      config_tempest/tests/test_config_tempest.py
  15. 3
      config_tempest/tests/test_credentials.py
  16. 3
      config_tempest/tests/test_flavors.py
  17. 2
      config_tempest/tests/test_profile.py
  18. 2
      config_tempest/tests/test_tempest_conf.py
  19. 2
      config_tempest/tests/test_users.py

@ -15,10 +15,11 @@
# License for the specific language governing permissions and limitations
# under the License.
from unittest import mock
from fixtures import MonkeyPatch
import json
import logging
import mock
from oslotest import base
from config_tempest.clients import ClientManager

@ -13,7 +13,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from config_tempest.services.aws import Ec2Service
from config_tempest.services.aws import S3Service

@ -13,7 +13,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from config_tempest.services.base import Service
from config_tempest.services.base import VersionedService

@ -13,7 +13,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from config_tempest.services.compute import ComputeService
from config_tempest.tempest_conf import TempestConf

@ -14,9 +14,9 @@
# under the License.
from ssl import CertificateError
from unittest import mock
from fixtures import MonkeyPatch
import mock
from config_tempest.services import horizon
from config_tempest.tests.base import BaseConfigTempestTest

@ -13,8 +13,9 @@
# License for the specific language governing permissions and limitations
# under the License.
from unittest import mock
from fixtures import MonkeyPatch
import mock
from config_tempest.services.identity import IdentityService
from config_tempest.tempest_conf import TempestConf

@ -13,8 +13,9 @@
# License for the specific language governing permissions and limitations
# under the License.
from unittest import mock
from fixtures import MonkeyPatch
import mock
from config_tempest.services.image import ImageService
from config_tempest.tempest_conf import TempestConf

@ -13,7 +13,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from config_tempest.services.network import NetworkService
from config_tempest.tempest_conf import TempestConf

@ -13,7 +13,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from config_tempest import main
from config_tempest.services.object_storage import ObjectStorageService

@ -15,7 +15,7 @@
from config_tempest.services.services import Services
from config_tempest.tests.base import BaseConfigTempestTest
import mock
from unittest import mock
class TestServices(BaseConfigTempestTest):

@ -13,7 +13,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from config_tempest.services import volume
from config_tempest.tempest_conf import TempestConf

@ -13,8 +13,8 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
import os
from unittest import mock
from config_tempest import accounts
from config_tempest import main

@ -15,8 +15,9 @@
# License for the specific language governing permissions and limitations
# under the License.
from unittest import mock
from fixtures import MonkeyPatch
import mock
from config_tempest.clients import ClientManager
from config_tempest.clients import ProjectsClient

@ -15,8 +15,9 @@
# License for the specific language governing permissions and limitations
# under the License.
from unittest import mock
from fixtures import MonkeyPatch
import mock
from config_tempest.clients import ClientManager
from config_tempest import main as tool

@ -15,8 +15,9 @@
# License for the specific language governing permissions and limitations
# under the License.
from unittest import mock
from fixtures import MonkeyPatch
import mock
from config_tempest.tests.base import BaseConfigTempestTest

@ -13,8 +13,9 @@
# License for the specific language governing permissions and limitations
# under the License.
from unittest import mock
from fixtures import MonkeyPatch
import mock
from config_tempest import constants as C
from config_tempest.flavors import Flavors

@ -13,7 +13,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from config_tempest import profile
from config_tempest.tests.base import BaseConfigTempestTest

@ -15,7 +15,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from config_tempest import tempest_conf
from config_tempest.tests.base import BaseConfigTempestTest

@ -13,7 +13,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from config_tempest.tests.base import BaseConfigTempestTest
from config_tempest.users import Users

Loading…
Cancel
Save