def test_p1_rename_errors(p1):
    """Check wrong arguments trigger exceptions when renaming."""
    with pytest.raises(TypeError):
        p1.rename(5678)
    with pytest.raises(ValueError):
        p1.rename('KJLIZ')