def test_load_dict_json(self, tmpdir): a_dict = {'a': 'dict'} path = os.path.join(tmpdir, 'a.json') with open(path, 'w') as json_file: json.dump(a_dict, json_file) returned = functional._load_dict(path) assert returned == a_dict
def test_load_dict_none(self): returned = functional._load_dict(None) assert returned is None
def test_load_dict_dict(self): a_dict = {'a': 'dict'} returned = functional._load_dict(a_dict) assert returned is a_dict