DX: apply rector rulesset up to PHP72

This commit is contained in:
2023-03-29 22:32:52 +02:00
parent 64b8ae3df1
commit b9a7530f7a
110 changed files with 194 additions and 229 deletions

View File

@@ -279,8 +279,8 @@ final class AuthorizationHelperTest extends KernelTestCase
]);
$helper = $this->getAuthorizationHelper();
$entity = $this->getProphet()->prophesize();
$entity->willImplement('\Chill\MainBundle\Entity\HasCenterInterface');
$entity->willImplement('\Chill\MainBundle\Entity\HasScopeInterface');
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasCenterInterface::class);
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasScopeInterface::class);
$entity->getCenter()->willReturn($center);
$entity->getScope()->willReturn($scope);
@@ -386,7 +386,7 @@ final class AuthorizationHelperTest extends KernelTestCase
]);
$helper = $this->getAuthorizationHelper();
$entity = $this->getProphet()->prophesize();
$entity->willImplement('\Chill\MainBundle\Entity\HasCenterInterface');
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasCenterInterface::class);
$entity->getCenter()->willReturn($center);
$this->assertTrue($helper->userHasAccess(
@@ -410,7 +410,7 @@ final class AuthorizationHelperTest extends KernelTestCase
$helper = $this->getAuthorizationHelper();
$entity = $this->getProphet()->prophesize();
$entity->willImplement('\Chill\MainBundle\Entity\HasCenterInterface');
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasCenterInterface::class);
$entity->getCenter()->willReturn($center);
$this->assertTrue($helper->userHasAccess(
@@ -434,8 +434,8 @@ final class AuthorizationHelperTest extends KernelTestCase
]);
$helper = $this->getAuthorizationHelper();
$entity = $this->getProphet()->prophesize();
$entity->willImplement('\Chill\MainBundle\Entity\HasCenterInterface');
$entity->willImplement('\Chill\MainBundle\Entity\HasScopeInterface');
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasCenterInterface::class);
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasScopeInterface::class);
$entity->getCenter()->willReturn($centerB);
$entity->getScope()->willReturn($scope);
@@ -455,7 +455,7 @@ final class AuthorizationHelperTest extends KernelTestCase
]);
$helper = $this->getAuthorizationHelper();
$entity = $this->getProphet()->prophesize();
$entity->willImplement('\Chill\MainBundle\Entity\HasCenterInterface');
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasCenterInterface::class);
$entity->getCenter()->willReturn($center);
$this->assertFalse($helper->userHasAccess($user, $entity->reveal(), 'CHILL_ROLE'));
@@ -474,8 +474,8 @@ final class AuthorizationHelperTest extends KernelTestCase
]);
$helper = $this->getAuthorizationHelper();
$entity = $this->getProphet()->prophesize();
$entity->willImplement('\Chill\MainBundle\Entity\HasCenterInterface');
$entity->willImplement('\Chill\MainBundle\Entity\HasScopeInterface');
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasCenterInterface::class);
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasScopeInterface::class);
$entity->getCenter()->willReturn($center);
$entity->getScope()->willReturn($scope);
@@ -506,7 +506,7 @@ final class AuthorizationHelperTest extends KernelTestCase
]);
$helper = $this->getAuthorizationHelper();
$entity = $this->getProphet()->prophesize();
$entity->willImplement('\Chill\MainBundle\Entity\HasCenterInterface');
$entity->willImplement('\\' . \Chill\MainBundle\Entity\HasCenterInterface::class);
$entity->getCenter()->willReturn($centerA);
$this->assertFalse($helper->userHasAccess($user, $entity->reveal(), 'CHILL_ROLE'));