def test_load_config_empty_file(self):
"""
Test loading of the config attr if the config file is empty
"""
usrmgr = self.__get_dummy_object()
with patch("os.path.exists", return_value=True),\
patch("ownbot.usermanager.open") as open_mock:
open_mock.return_value = io.BytesIO(b"")
self.assertEqual(usrmgr.config, {})
self.assertTrue(open_mock.called)
评论列表
文章目录