Browse Source

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: I0b5e9e60b00204f938d23fc4ff8e020ebb4afa43
changes/34/734334/3
Hervé Beraud 10 months ago
committed by Jeremy Stanley
parent
commit
c08aed239d
3 changed files with 2 additions and 3 deletions
  1. +1
    -1
      openstack_election/tests/cmds/test_ci_checks.py
  2. +1
    -1
      openstack_election/tests/test_utils.py
  3. +0
    -1
      test-requirements.txt

+ 1
- 1
openstack_election/tests/cmds/test_ci_checks.py View File

@ -10,7 +10,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from openstack_election.cmds import ci_check_all_candidate_files
from openstack_election.tests import base


+ 1
- 1
openstack_election/tests/test_utils.py View File

@ -10,7 +10,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import mock
from unittest import mock
from openstack_election import exception
from openstack_election.tests import base


+ 0
- 1
test-requirements.txt View File

@ -4,7 +4,6 @@
# needed for doc build
hacking>=3.1.0,<3.2.0 # Apache-2.0
yamllint
mock>=2.0.0 # BSD
oslotest>=1.10.0 # Apache-2.0
stestr>=2.0.0 # Apache-2.0
testresources>=2.0.0 # Apache-2.0/BSD


Loading…
Cancel
Save