def test__load_yaml_success(loader): res = loader._load_yaml('---\ntest: string') assert isinstance(res, dict) assert res['test'] == 'string' res = loader._load_yaml('{"test": "string"}') assert isinstance(res, dict) assert res['test'] == 'string'
def test__load_yaml_failure(loader): res = loader._load_yaml('---\ntest: string:') assert res is None