mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-28 18:43:49 +00:00
upgrade phpunit: make data provider static
This commit is contained in:
@@ -42,7 +42,7 @@ final class CalendarControllerTest extends WebTestCase
|
||||
self::ensureKernelShutdown();
|
||||
}
|
||||
|
||||
public function provideAccompanyingPeriod(): iterable
|
||||
public static function provideAccompanyingPeriod(): iterable
|
||||
{
|
||||
self::bootKernel();
|
||||
$em = self::getContainer()->get(EntityManagerInterface::class);
|
||||
|
@@ -59,7 +59,7 @@ class MSUserAbsenceReaderTest extends TestCase
|
||||
self::assertNull($absenceReader->isUserAbsent($user), 'when no user found, absence should be null');
|
||||
}
|
||||
|
||||
public function provideDataTestUserAbsence(): iterable
|
||||
public static function provideDataTestUserAbsence(): iterable
|
||||
{
|
||||
// contains data that was retrieved from microsoft graph api on 2023-07-06
|
||||
|
||||
|
@@ -46,7 +46,7 @@ class MSUserAbsenceSyncTest extends TestCase
|
||||
self::assertEquals($expectedAbsenceStart, $user->getAbsenceStart(), $message);
|
||||
}
|
||||
|
||||
public function provideDataTestSyncUserAbsence(): iterable
|
||||
public static function provideDataTestSyncUserAbsence(): iterable
|
||||
{
|
||||
yield [new User(), false, false, null, 'user present remains present'];
|
||||
yield [new User(), true, true, new \DateTimeImmutable('2023-07-01T12:00:00'), 'user present becomes absent'];
|
||||
|
@@ -35,7 +35,7 @@ final class DefaultRangeGeneratorTest extends TestCase
|
||||
* * Jeudi => envoi des rdv du samedi et dimanche
|
||||
* * Vendredi => Envoi des rdv du lundi.
|
||||
*/
|
||||
public function generateData(): \Iterator
|
||||
public static function generateData(): \Iterator
|
||||
{
|
||||
yield [
|
||||
new \DateTimeImmutable('2022-06-13 10:45:00'),
|
||||
|
Reference in New Issue
Block a user