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

@@ -15,6 +15,7 @@ use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
/**
* @internal
*
* @coversNothing
*/
final class ElementControllerTest extends WebTestCase

View File

@@ -20,15 +20,12 @@ use Chill\MainBundle\Templating\TranslatableStringHelperInterface;
use Chill\PersonBundle\Entity\Household\Household;
use Chill\PersonBundle\Entity\Household\HouseholdMember;
use Chill\PersonBundle\Entity\Person;
use DateTimeImmutable;
use Doctrine\ORM\AbstractQuery;
use Doctrine\ORM\EntityManagerInterface;
use Doctrine\ORM\Query;
use PHPUnit\Framework\TestCase;
use Prophecy\Argument;
use Prophecy\PhpUnit\ProphecyTrait;
use ReflectionClass;
use RuntimeException;
/**
* @internal
@@ -74,7 +71,7 @@ final class SummaryBudgetTest extends TestCase
return $queryCharges->reveal();
}
throw new RuntimeException('this query does not have a stub counterpart: ' . $args[0]);
throw new \RuntimeException('this query does not have a stub counterpart: '.$args[0]);
});
$chargeRepository = $this->prophesize(ChargeKindRepositoryInterface::class);
@@ -99,18 +96,18 @@ final class SummaryBudgetTest extends TestCase
$translatableStringHelper->localize(Argument::type('array'))->will(static fn ($arg) => $arg[0]['fr']);
$person = new Person();
$personReflection = new ReflectionClass($person);
$personReflection = new \ReflectionClass($person);
$personIdReflection = $personReflection->getProperty('id');
$personIdReflection->setAccessible(true);
$personIdReflection->setValue($person, 1);
$household = new Household();
$householdReflection = new ReflectionClass($household);
$householdReflection = new \ReflectionClass($household);
$householdId = $householdReflection->getProperty('id');
$householdId->setAccessible(true);
$householdId->setValue($household, 1);
$householdMember = (new HouseholdMember())->setPerson($person)
->setStartDate(new DateTimeImmutable('1 month ago'));
->setStartDate(new \DateTimeImmutable('1 month ago'));
$household->addMember($householdMember);
$summaryBudget = new SummaryBudget(