mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-02 21:13:57 +00:00
fix some tests
This commit is contained in:
@@ -16,6 +16,7 @@ use Chill\DocStoreBundle\AsyncUpload\SignedUrlPost;
|
||||
use Chill\DocStoreBundle\AsyncUpload\TempUrlGeneratorInterface;
|
||||
use Chill\DocStoreBundle\Controller\AsyncUploadController;
|
||||
use Chill\DocStoreBundle\Entity\StoredObject;
|
||||
use Chill\MainBundle\Entity\User;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use Prophecy\Argument;
|
||||
use Prophecy\PhpUnit\ProphecyTrait;
|
||||
@@ -61,6 +62,7 @@ class AsyncUploadControllerTest extends TestCase
|
||||
$storedObject->registerVersion();
|
||||
$security = $this->prophesize(Security::class);
|
||||
$security->isGranted('SEE', $storedObject)->willReturn(true)->shouldBeCalled();
|
||||
$security->getUser()->willReturn(new User());
|
||||
|
||||
$controller = new AsyncUploadController(
|
||||
$this->buildTempUrlGenerator(),
|
||||
@@ -105,6 +107,7 @@ class AsyncUploadControllerTest extends TestCase
|
||||
|
||||
$security = $this->prophesize(Security::class);
|
||||
$security->isGranted('SEE', $storedObject)->willReturn(true)->shouldBeCalled();
|
||||
$security->getUser()->willReturn(new User());
|
||||
|
||||
$controller = new AsyncUploadController(
|
||||
$this->buildTempUrlGenerator(),
|
||||
@@ -136,6 +139,7 @@ class AsyncUploadControllerTest extends TestCase
|
||||
|
||||
$security = $this->prophesize(Security::class);
|
||||
$security->isGranted('SEE', $storedObject)->willReturn(true)->shouldBeCalled();
|
||||
$security->getUser()->willReturn(new User());
|
||||
|
||||
$controller = new AsyncUploadController(
|
||||
$this->buildTempUrlGenerator(),
|
||||
|
Reference in New Issue
Block a user