aboutsummaryrefslogtreecommitdiff
path: root/kolla
diff options
context:
space:
mode:
authorRadosław Piliszek <radoslaw.piliszek@gmail.com>2020-04-02 18:22:38 +0200
committerRadosław Piliszek <radoslaw.piliszek@gmail.com>2020-04-02 18:22:38 +0200
commit924e7a40f185fd3116d593ba0353046bd7c81e1b (patch)
treeb2d8955edcbd080e8b185ee76aed3a130203a60f /kolla
parent69f74554671a49c75bebeeed9d83816ffbd7efec (diff)
downloadkolla-924e7a40f185fd3116d593ba0353046bd7c81e1b.tar.gz
kolla-924e7a40f185fd3116d593ba0353046bd7c81e1b.zip
Use unittest.mock instead of PyPI mock
Now that py2 is gone, oslotest dropped dependency on mock and will soon affect Ussuri CI [1], let's use unittest.mock built in py3. This also fixes py38 jobs and proactively prevents py36 and py37 failing due to [1]. This is because we never included mock in test-requirements (but in lower-constraints where it does not really belong at all) and instead relied on oslotest to bring it in. [1] https://review.opendev.org/716322 Change-Id: Iceedcc7ad0d087414f6f94dfc0235fda4754be63
Diffstat (limited to 'kolla')
-rw-r--r--kolla/tests/base.py2
-rw-r--r--kolla/tests/test_build.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/kolla/tests/base.py b/kolla/tests/base.py
index 1c43b7619..94bdba509 100644
--- a/kolla/tests/base.py
+++ b/kolla/tests/base.py
@@ -11,9 +11,9 @@
# limitations under the License.
import os
+from unittest import mock
import fixtures
-import mock
from oslo_config import cfg
from oslotest import base as oslotest_base
diff --git a/kolla/tests/test_build.py b/kolla/tests/test_build.py
index 5b3e981d6..b7f5c30c0 100644
--- a/kolla/tests/test_build.py
+++ b/kolla/tests/test_build.py
@@ -12,10 +12,10 @@
import fixtures
import itertools
-import mock
import os
import requests
import sys
+from unittest import mock
from kolla.cmd import build as build_cmd
from kolla import exception