diff --git a/tests/Feature/Api/ProcessTest.php b/tests/Feature/Api/ProcessTest.php index 4f0bd1824c..848fc337f6 100644 --- a/tests/Feature/Api/ProcessTest.php +++ b/tests/Feature/Api/ProcessTest.php @@ -1273,13 +1273,12 @@ public function testGetMediaImagesRoute() public function testDeleteMediaImages() { $process = Process::factory()->create(); - $faker = app(Faker::class); - $imageContent = file_get_contents($faker->imageUrl()); + $imageContent = file_get_contents(__DIR__.'/images/640x480.png'); $imagePath = storage_path('app/test-image.jpg'); + file_put_contents($imagePath, $imageContent); - - $uploadedFile = new UploadedFile($imagePath, 'test-image.jpg', 'image/jpeg', null, true); + $uploadedFile = new UploadedFile($imagePath, 'test-image.jpg', 'image/jpeg', null, true); $process->addMedia($uploadedFile)->toMediaCollection('images_carousel'); $mediaImagen = $process->getFirstMedia('images_carousel'); diff --git a/tests/Feature/Api/images/640x480.png b/tests/Feature/Api/images/640x480.png new file mode 100644 index 0000000000..616183f84c Binary files /dev/null and b/tests/Feature/Api/images/640x480.png differ