apply more cs rules for php-cs

This commit is contained in:
2023-10-17 13:27:03 +02:00
parent 0b0cbed9db
commit bc2041cbdd
1485 changed files with 8169 additions and 9620 deletions

View File

@@ -20,7 +20,6 @@ use Chill\MainBundle\Security\Resolver\CenterResolverManagerInterface;
use Chill\PersonBundle\Entity\AccompanyingPeriod;
use Chill\PersonBundle\Entity\Person;
use Doctrine\ORM\EntityManagerInterface;
use phpseclib3\Math\BinaryField;
use Prophecy\Argument;
use Prophecy\PhpUnit\ProphecyTrait;
use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase;
@@ -28,6 +27,7 @@ use Symfony\Component\Security\Core\Security;
/**
* @internal
*
* @coversNothing
*/
class ActivityDocumentACLAwareRepositoryTest extends KernelTestCase
@@ -104,22 +104,22 @@ class ActivityDocumentACLAwareRepositoryTest extends KernelTestCase
{
$this->setUp();
if (null === $person = $this->entityManager->createQuery("SELECT p FROM " . Person::class . " p WHERE SIZE(p.accompanyingPeriodParticipations) > 0 ")
if (null === $person = $this->entityManager->createQuery('SELECT p FROM '.Person::class.' p WHERE SIZE(p.accompanyingPeriodParticipations) > 0 ')
->setMaxResults(1)
->getSingleResult()) {
throw new \RuntimeException("no person in dtabase");
throw new \RuntimeException('no person in dtabase');
}
if ([] === $scopes = $this->entityManager->createQuery("SELECT s FROM " . Scope::class . " s ")->setMaxResults(5)->getResult()) {
throw new \RuntimeException("no scopes in database");
if ([] === $scopes = $this->entityManager->createQuery('SELECT s FROM '.Scope::class.' s ')->setMaxResults(5)->getResult()) {
throw new \RuntimeException('no scopes in database');
}
yield [$person, [], true, null, null, null];
yield [$person, $scopes, true, null, null, null];
yield [$person, $scopes, true, new \DateTimeImmutable("1 month ago"), null, null];
yield [$person, $scopes, true, new \DateTimeImmutable("1 month ago"), new \DateTimeImmutable("1 week ago"), null];
yield [$person, $scopes, true, new \DateTimeImmutable("1 month ago"), new \DateTimeImmutable("1 week ago"), "content"];
yield [$person, $scopes, true, null, new \DateTimeImmutable("1 week ago"), "content"];
yield [$person, [], true, new \DateTimeImmutable("1 month ago"), new \DateTimeImmutable("1 week ago"), "content"];
yield [$person, $scopes, true, new \DateTimeImmutable('1 month ago'), null, null];
yield [$person, $scopes, true, new \DateTimeImmutable('1 month ago'), new \DateTimeImmutable('1 week ago'), null];
yield [$person, $scopes, true, new \DateTimeImmutable('1 month ago'), new \DateTimeImmutable('1 week ago'), 'content'];
yield [$person, $scopes, true, null, new \DateTimeImmutable('1 week ago'), 'content'];
yield [$person, [], true, new \DateTimeImmutable('1 month ago'), new \DateTimeImmutable('1 week ago'), 'content'];
}
}