I want to patch multiples method of same object. I am trying
@patch.multiple('pdb.Pdb', do_continue=DEFAULT, do_step=DEFAULT, do_exit=DEFAULT)
it throws error during running Test
NameError: name 'DEFAULT' is not defined
unittest.mock.DEFAULT
needs to be imported first. This will run without error:
from unittest.mock import patch
from unittest.mock import DEFAULT
patch.multiple('pdb.Pdb', do_continue=DEFAULT, do_step=DEFAULT, do_exit=DEFAULT)