Autospecing will ensure that the method signatures are respected
during calls.
oslotest.mock_fixture contains 2 components, one of them adds the autospec
argument to mock.Mock and mock.MagicMock, while the other one fixes the
autospec behaviour for mock.patch functions, and sets autospec to True by
default, unless otherwise specified.
Reviewed: https:/ /review. openstack. org/532947 /git.openstack. org/cgit/ openstack/ networking- hyperv/ commit/ ?id=d5b72f4250c e3a60fb85f751c9 9fbba88a71ced0
Committed: https:/
Submitter: Zuul
Branch: master
commit d5b72f4250ce3a6 0fb85f751c99fbb a88a71ced0
Author: Claudiu Belu <email address hidden>
Date: Tue Jan 9 05:53:42 2018 -0800
tests: Use mock autospec in unit tests
Autospecing will ensure that the method signatures are respected
during calls.
oslotest. mock_fixture contains 2 components, one of them adds the autospec
argument to mock.Mock and mock.MagicMock, while the other one fixes the
autospec behaviour for mock.patch functions, and sets autospec to True by
default, unless otherwise specified.
Change-Id: Ib785be16e2b81a 32dff32b0e070e3 4e0675d4b4f
Closes-Bug: #1735588