Use unittest.mock instead of mock
The mock third party library was needed for mock support in py2 runtimes. Since we now only support py36 and later, we can use the standard lib unittest.mock module instead. Change-Id: I4c7cb63e0a816b361c2544b1be34d8a6dadeb5c0
This commit is contained in:
@@ -43,7 +43,6 @@ linecache2==1.0.0
|
||||
Mako==0.4.0
|
||||
MarkupSafe==1.0
|
||||
mccabe==0.2.1
|
||||
mock==2.0.0
|
||||
monasca-common==2.16.0
|
||||
monotonic==0.6
|
||||
mox3==0.20.0
|
||||
|
@@ -24,7 +24,7 @@ import falcon.testing
|
||||
import fixtures
|
||||
import testtools.matchers as matchers
|
||||
|
||||
from mock import Mock
|
||||
from unittest.mock import Mock
|
||||
|
||||
import oslo_config.fixture
|
||||
import six
|
||||
|
@@ -14,7 +14,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from mock import Mock
|
||||
from unittest.mock import Mock
|
||||
|
||||
from monasca_api.tests import base
|
||||
from monasca_api.v2.reference import helpers
|
||||
|
@@ -21,7 +21,7 @@ from datetime import datetime
|
||||
|
||||
import cassandra
|
||||
from cassandra.auth import PlainTextAuthProvider
|
||||
from mock import patch
|
||||
from unittest.mock import patch
|
||||
|
||||
from oslo_config import cfg
|
||||
from oslo_utils import timeutils
|
||||
|
Reference in New Issue
Block a user