This commit is contained in:
@@ -16,8 +16,10 @@ class MultiDownloaderClientTest extends TestCase
|
||||
private function testFiles()
|
||||
{
|
||||
return array_map(function ($url, $i) {
|
||||
return (new FileRequest($url))
|
||||
->fileOptions(['name' => 'test' . $i . '.png']);
|
||||
$file = new FileRequest($url);
|
||||
$file->getFileOptions()->name('test' . $i . '.png');
|
||||
|
||||
return $file;
|
||||
}, $this->testFiles, array_keys($this->testFiles));
|
||||
}
|
||||
|
||||
@@ -38,7 +40,7 @@ class MultiDownloaderClientTest extends TestCase
|
||||
{
|
||||
$client = new MultiDownloaderClient(['apiKey' => 'test', 'apiSecret' => 'test']);
|
||||
|
||||
$path = __DIR__ . '/testDownloadTo.zip';
|
||||
$path = sys_get_temp_dir() . '/testDownloadTo.zip';
|
||||
|
||||
$client->setFiles($this->testFiles());
|
||||
$client->downloadTo($path);
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user