diff --git a/ironic/tests/base.py b/ironic/tests/base.py index eccdb9a1bf..e19a2380ce 100644 --- a/ironic/tests/base.py +++ b/ironic/tests/base.py @@ -55,7 +55,7 @@ logging.setup(CONF, 'ironic') # NOTE(rpittau) this function allows autospec for classmethods and -# staticmethods in Python 3.6, while no issue occurs in Python 3.7 +# staticmethods in Python 3.6, while no issue occurs in Python 3.7.4 # and later. # For more info please see: http://bugs.python.org/issue23078 def _patch_mock_callable(obj): @@ -133,7 +133,7 @@ class TestCase(oslo_test_base.BaseTestCase): # subprocess.Popen is a class self.patch(subprocess, 'Popen', DoNotCallPopen) - if sys.version_info < (3, 7): + if sys.version_info < (3, 7, 4): _patch_mock_callable._old_func = mock._callable mock._callable = _patch_mock_callable