def _create_master(): ''' Create master instance :return: ''' master = daemons.Master() master.config = {'user': '******', 'hash_type': alg} for attr in ['master', 'start_log_info', 'prepare']: setattr(master, attr, MagicMock()) return master
def _create_master(): """ Create master instance :return: """ obj = daemons.Master() obj.config = {"user": "******", "hash_type": alg} for attr in ["start_log_info", "prepare", "shutdown", "master"]: setattr(obj, attr, MagicMock()) return obj
def _create_master(): ''' Create master instance :return: ''' obj = daemons.Master() obj.config = {'user': '******', 'hash_type': alg} for attr in ['start_log_info', 'prepare', 'shutdown', 'master']: setattr(obj, attr, MagicMock()) return obj