When you call $enitity->uri()
function on file entities, it does not return the same result as other entity types. Most other entity types return an array with two keys - path and options - with the path being something like "node/1" and the options contain other url options like fragment.
However, files completely exclude the options key, and we should have it return an empty array:
https://api.backdropcms.org/api/backdrop/core%21modules%21system%21file.entity.inc/function/File%3A%3Auri/1