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: I35d6f1207b57ea40809f78785c69a13c2943e1bc Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import mock
|
||||
from unittest import mock
|
||||
|
||||
from solumclient.builder import client
|
||||
from solumclient.common.apiclient import exceptions
|
||||
|
@@ -12,8 +12,9 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from unittest import mock
|
||||
|
||||
from keystoneclient.v2_0 import client as ksclient
|
||||
import mock
|
||||
import testtools
|
||||
|
||||
from solumclient.common import auth
|
||||
|
@@ -12,8 +12,8 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import mock
|
||||
import requests
|
||||
from unittest import mock
|
||||
|
||||
from solumclient.common.apiclient import auth
|
||||
from solumclient.common.apiclient import client as api_client
|
||||
|
@@ -13,8 +13,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
from unittest import mock
|
||||
|
||||
import fixtures
|
||||
import mock
|
||||
|
||||
from solumclient import client as solum_client
|
||||
from solumclient.common import cli_utils
|
||||
|
@@ -14,8 +14,8 @@
|
||||
# limitations under the License.
|
||||
|
||||
import json
|
||||
from unittest import mock
|
||||
|
||||
import mock
|
||||
|
||||
from solumclient.common import github
|
||||
from solumclient.tests import base
|
||||
|
@@ -10,7 +10,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import mock
|
||||
from unittest import mock
|
||||
import yaml
|
||||
|
||||
from solumclient.common import yamlutils
|
||||
|
@@ -12,7 +12,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import mock
|
||||
from unittest import mock
|
||||
|
||||
from solumclient import client
|
||||
from solumclient.common.apiclient import exceptions
|
||||
|
@@ -13,13 +13,13 @@
|
||||
# under the License.
|
||||
|
||||
from io import StringIO
|
||||
from unittest import mock
|
||||
|
||||
import collections
|
||||
import re
|
||||
import sys
|
||||
|
||||
import fixtures
|
||||
import mock
|
||||
|
||||
from oslo_utils import uuidutils
|
||||
|
||||
|
@@ -12,7 +12,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import mock
|
||||
from unittest import mock
|
||||
|
||||
from solumclient.common.apiclient import client
|
||||
from solumclient.common.apiclient import fake_client
|
||||
|
@@ -9,4 +9,3 @@ oslotest>=3.2.0 # Apache-2.0
|
||||
stestr>=2.0.0 # Apache-2.0
|
||||
testscenarios>=0.4 # Apache-2.0/BSD
|
||||
testtools>=2.2.0 # MIT
|
||||
mock>=2.0.0 # BSD
|
||||
|
Reference in New Issue
Block a user