def METHOD_NAME(filepath: str | os.PathLike) -> None:
    """Assert that filepath points to an existing file. Print all the elements (files and dir) of the parent dir of the given filepath.
    This is mostly to have better assert message than using a raw assert filepath.is_file().
    Parameters
    ----------
    filepath
        Filepath to check.
    Raises
    ------
    AssertionError
        If filepath does not point to a file (if the file does not exist or it's a dir).
    """
    path = Path(filepath)
    if not path.is_file():
        elems = pformat([path.name for path in path.parent.iterdir()])
        message = f"{path.absolute()} is not a file. Other elements in the parent directory are \n{elems}"
        raise AssertionError(message)