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: I7e645c6fcc302ed152c57e997c32ebe658e4d0bd
This commit is contained in:
Hervé Beraud 2020-06-08 22:37:47 +02:00
parent b661e63789
commit 455cc94d0f
4 changed files with 3 additions and 4 deletions

View File

@ -9,7 +9,6 @@
#
charm-tools>=2.4.4
requests>=2.18.4
mock>=1.2
flake8>=2.2.4
stestr>=2.2.0
coverage>=4.5.2

View File

@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from mock import MagicMock, patch, call, ANY
from unittest.mock import MagicMock, patch, call, ANY
import os
import json
import cinder_utils as utils

View File

@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from mock import patch, call
from unittest.mock import patch, call
import os
import cinder_utils as cinder_utils

View File

@ -17,7 +17,7 @@ import unittest
import os
import yaml
from mock import patch
from unittest.mock import patch
def load_config():