def METHOD_NAME(version):
    """Decorator to mark a test as xfail with ExpiredDeprecationError after version"""
    from packaging.version import Version
    from nibabel import __version__ as nbver
    from nibabel.deprecator import ExpiredDeprecationError
    if Version(nbver) < Version(version):
        return lambda x: x
    return pytest.mark.xfail(raises=ExpiredDeprecationError)