Use getPathname() instead of string casting to get BinaryFileReponse file path

According to the code, should be "File" instead of "\SplFileInfo"
This test will fail on Windows because of directory separator mismatch