public function test_upload_object()
 {
     $this->assertInstanceOf('\\Dugun\\UploadBundle\\Service\\DugunUploadService', $this->service);
     $interventionImageManager = new ImageManager();
     $image = $interventionImageManager->make(__DIR__ . '/../Resources/assets/test/file1.jpg');
     $this->service->upload($image, 'test.jpg', $delete = false, $overwrite = true);
     $image = new UploadedFile(__DIR__ . '/../Resources/assets/test/file1.jpg', 'file1.jpg', 'image/jpeg');
     $result = $this->service->upload($image, 'test.jpg', $delete = false, $overwrite = true);
 }
 public function test_upload_object()
 {
     $this->assertInstanceOf('\\Dugun\\UploadBundle\\Service\\DugunUploadService', $this->service);
     $this->service->setUploaderService('dugun_image_microservice');
     $image = new UploadedFile(__DIR__ . '/../Resources/assets/test/file1.jpg', 'file1.jpg', 'image/jpeg');
     $response = $this->service->upload($image, 't2/test77.jpg', $delete = false, $overwrite = true);
     $this->assertTrue(is_array($response));
     $this->assertArrayHasKey('success', $response);
     $this->assertTrue($response['success']);
 }
 public function test_download_object()
 {
     $this->assertInstanceOf('\\Dugun\\UploadBundle\\Service\\DugunUploadService', $this->service);
     $file = $this->service->download('test.jpg');
 }
 public function test_get_object()
 {
     $this->assertInstanceOf('\\Dugun\\UploadBundle\\Service\\DugunUploadService', $this->service);
     $result = $this->service->doesObjectExist('t2/test4.jpg');
     $this->assertTrue($result);
 }