def METHOD_NAME():
    new_formula = FormulaHandler.rename_field_references_in_formula_string(
        "field('test with \\'')", {"test with '": "new test with ' \\' and \" and \\\""}
    )
    assert new_formula == "field('new test with \\' \\\\' and \" and \\\"')"