diff options
author | Sean McGinnis <sean.mcginnis@gmail.com> | 2020-03-31 14:04:15 -0500 |
---|---|---|
committer | Sean McGinnis <sean.mcginnis@gmail.com> | 2020-03-31 14:39:24 -0500 |
commit | 2163443d8abde9f550bf5d6681889bcdfc088757 (patch) | |
tree | ccb098c12509de3eb9e4196a43663b9b065de07f /oslo_utils/tests | |
parent | 8433aba4d6b5925fa8fb223d51a816ff541f1f2f (diff) | |
download | oslo-utils-2163443d8abde9f550bf5d6681889bcdfc088757.tar.gz |
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: I4c5451afece8dfff30aa1ec4c7e0d5eb277043fd
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
Diffstat (limited to 'oslo_utils/tests')
-rw-r--r-- | oslo_utils/tests/test_eventletutils.py | 2 | ||||
-rw-r--r-- | oslo_utils/tests/test_excutils.py | 2 | ||||
-rw-r--r-- | oslo_utils/tests/test_fnmatch.py | 2 | ||||
-rw-r--r-- | oslo_utils/tests/test_netutils.py | 2 | ||||
-rw-r--r-- | oslo_utils/tests/test_strutils.py | 2 | ||||
-rw-r--r-- | oslo_utils/tests/test_timeutils.py | 2 | ||||
-rw-r--r-- | oslo_utils/tests/tests_encodeutils.py | 3 |
7 files changed, 8 insertions, 7 deletions
diff --git a/oslo_utils/tests/test_eventletutils.py b/oslo_utils/tests/test_eventletutils.py index d96851c..62b72af 100644 --- a/oslo_utils/tests/test_eventletutils.py +++ b/oslo_utils/tests/test_eventletutils.py @@ -13,11 +13,11 @@ # under the License. import threading +from unittest import mock import warnings import eventlet from eventlet import greenthread -import mock from oslotest import base as test_base import six diff --git a/oslo_utils/tests/test_excutils.py b/oslo_utils/tests/test_excutils.py index 204791f..011d016 100644 --- a/oslo_utils/tests/test_excutils.py +++ b/oslo_utils/tests/test_excutils.py @@ -13,9 +13,9 @@ # under the License. import logging +from unittest import mock import fixtures -import mock from oslotest import base as test_base from oslo_utils import excutils diff --git a/oslo_utils/tests/test_fnmatch.py b/oslo_utils/tests/test_fnmatch.py index 2c94dea..ae8415e 100644 --- a/oslo_utils/tests/test_fnmatch.py +++ b/oslo_utils/tests/test_fnmatch.py @@ -16,8 +16,8 @@ import fnmatch as standard_fnmatch import ntpath import posixpath import sys +from unittest import mock -import mock from oslotest import base import six diff --git a/oslo_utils/tests/test_netutils.py b/oslo_utils/tests/test_netutils.py index 856b671..31d9c75 100644 --- a/oslo_utils/tests/test_netutils.py +++ b/oslo_utils/tests/test_netutils.py @@ -15,8 +15,8 @@ import contextlib import socket +from unittest import mock -import mock import netifaces from oslotest import base as test_base import six diff --git a/oslo_utils/tests/test_strutils.py b/oslo_utils/tests/test_strutils.py index 25e974c..9ced05c 100644 --- a/oslo_utils/tests/test_strutils.py +++ b/oslo_utils/tests/test_strutils.py @@ -18,9 +18,9 @@ import collections import copy import math +from unittest import mock import ddt -import mock from oslotest import base as test_base import six import testscenarios diff --git a/oslo_utils/tests/test_timeutils.py b/oslo_utils/tests/test_timeutils.py index 77b1aa1..9466849 100644 --- a/oslo_utils/tests/test_timeutils.py +++ b/oslo_utils/tests/test_timeutils.py @@ -17,9 +17,9 @@ import calendar import datetime import logging import time +from unittest import mock import iso8601 -import mock from oslotest import base as test_base from testtools import matchers diff --git a/oslo_utils/tests/tests_encodeutils.py b/oslo_utils/tests/tests_encodeutils.py index 834c6d2..546e8ea 100644 --- a/oslo_utils/tests/tests_encodeutils.py +++ b/oslo_utils/tests/tests_encodeutils.py @@ -15,7 +15,8 @@ # License for the specific language governing permissions and limitations # under the License. -import mock +from unittest import mock + from oslo_i18n import fixture as oslo_i18n_fixture from oslotest import base as test_base import six |