@inrupt/solid-client
    Preparing search index...

    Function mockFileFrom

    • Do not use this function in production code. For use in **unit tests**.
      

      This function initialises a new File with metadata as though the File has been retrieved from the given URL. The mock File can be used in unit tests that require persisted Files; e.g. unit tests that call [[getSourceUrl]].

      Parameters

      • url: string | Url

        The URL from which the returned File appears to be retrieved.

      • Optionaloptions: Partial<{ contentType: undefined | string }>

      Returns Blob & WithResourceInfo & {}

      A mock File that appears to be retrieved from the url.

      0.2.0