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: I597461bc2ce6a480ea18950ded606ef7db717f2d Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
This commit is contained in:
parent
e7908d07f9
commit
34aaaf2eb5
@ -19,7 +19,6 @@ keystoneauth1==3.4.0
|
||||
linecache2==1.0.0
|
||||
MarkupSafe==1.0
|
||||
mccabe==0.2.1
|
||||
mock==2.0.0
|
||||
mox3==0.20.0
|
||||
netaddr==0.7.18
|
||||
openstackdocstheme==1.18.1
|
||||
|
@ -14,7 +14,8 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import mock
|
||||
from unittest import mock
|
||||
|
||||
from oslotest import base as test_base
|
||||
import six
|
||||
|
||||
|
@ -16,9 +16,9 @@
|
||||
|
||||
import gettext
|
||||
import logging
|
||||
from unittest import mock
|
||||
|
||||
from babel import localedata
|
||||
import mock
|
||||
from oslotest import base as test_base
|
||||
import six
|
||||
|
||||
|
@ -15,8 +15,8 @@
|
||||
# under the License.
|
||||
|
||||
import logging
|
||||
from unittest import mock
|
||||
|
||||
import mock
|
||||
from oslotest import base as test_base
|
||||
import six
|
||||
|
||||
|
@ -14,7 +14,8 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import mock
|
||||
from unittest import mock
|
||||
|
||||
from oslotest import base as test_base
|
||||
|
||||
from oslo_i18n import _factory
|
||||
|
@ -17,9 +17,9 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import logging
|
||||
from unittest import mock
|
||||
import warnings
|
||||
|
||||
import mock
|
||||
from oslotest import base as test_base
|
||||
import six
|
||||
import testtools
|
||||
|
@ -9,12 +9,10 @@
|
||||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
"""A few tests that use the public API to ensure the imports work.
|
||||
"""
|
||||
"""A few tests that use the public API to ensure the imports work."""
|
||||
|
||||
import unittest
|
||||
|
||||
import mock
|
||||
from unittest import mock
|
||||
|
||||
import oslo_i18n
|
||||
from oslo_i18n import _lazy
|
||||
|
@ -16,7 +16,8 @@
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import mock
|
||||
from unittest import mock
|
||||
|
||||
from oslotest import base as test_base
|
||||
|
||||
from oslo_i18n import _message
|
||||
|
@ -4,7 +4,6 @@
|
||||
hacking>=3.0,<3.1.0 # Apache-2.0
|
||||
stestr>=2.0.0 # Apache-2.0
|
||||
|
||||
mock>=2.0.0 # BSD
|
||||
oslotest>=3.2.0 # Apache-2.0
|
||||
coverage!=4.4,>=4.0 # Apache-2.0
|
||||
testscenarios>=0.4 # Apache-2.0/BSD
|
||||
|
Loading…
x
Reference in New Issue
Block a user