How to create a PHP-Unit test for a file download?
<p>after long thinking about this topic without a result, I hope someone can give me a hint about phpUnit-Test for downloads.  How can I create a phpUnit test for this function, which execute a download for a zip-File? Or is there an oter usual practice  to test a logic like this?</p>

<pre><code>   public function createOutput($zipFolderName) {
        $zipFolderName = $zipFolderName."/imageResizer.zip";
        header('Content-Type: application/zip');
        header('Content-disposition: attachment; filename=' . $zipFolderName);
        header('Content-Length: ' . filesize($zipFolderName));
        readfile($zipFolderName);
    }
</code></pre>