def METHOD_NAME(tmp_path, monkeypatch):
    monkeypatch.setattr(
        "monkey_island.cc.repositories.local_storage_file_repository.get_all_regular_files_in_directory",  # noqa: E501
        lambda _: raise_(OSError()),
    )
    fss = LocalStorageFileRepository(tmp_path)
    with pytest.raises(repositories.RetrievalError):
        fss.get_all_file_names()