def METHOD_NAME(self, name, uri, sha_hash=None):
    """
    Replaces the file by the name with the file provided by the url/path.
    Parameters
    ----------
    name : `str`
        Name of the file provided in the `require` decorator.
    uri : `str`
        URI of the file which replaces original file. Scheme should be one
        of ``http``, ``https``, ``ftp`` or ``file``. If no scheme is given
        the uri will be interpreted as a local path. i.e.
        ``file:///tmp/test`` and ``/tmp/test`` are the same.
    sha_hash : `str`, optional
        SHA256 hash of the file to compared to after downloading.
    """
    try:
        self._skip_file[name] = {
            'uri': uri,
            'hash': sha_hash,
        }
        yield
    finally:
        _ = self._skip_file.pop(name, None)