def METHOD_NAME(tmpdir, projection):
    if "projections" not in projection:
        projection = {"projections": projection}
    projection_file = tmpdir.mkdir("projection").join("projection.yaml")
    projection_file.write(s_yaml.dump(projection))
    return projection_file