test_walk_moler_nonabstract_commands_raise_exception_when_called move import
@@ -122,10 +122,11 @@ def test_genertors_return_files_without_dunder_init(func2test, method_param):
def test_walk_moler_nonabstract_commands_raise_exception_when_called(fake_cmd):
+ from moler.util.cmds_doc import _walk_moler_nonabstract_commands
+
with mock.patch('moler.util.cmds_doc._walk_moler_commands', return_value=(None, fake_cmd)):
- from moler.util import cmds_doc
with raises(Exception):
- next(cmds_doc._walk_moler_nonabstract_commands(cmd_dir_under_test))
+ next(_walk_moler_nonabstract_commands(cmd_dir_under_test))
def test_retrieve_command_documentation_as_dict():
