diff --git a/tests/units/Afup/Association/Cotisations.php b/tests/units/Afup/Association/Cotisations.php index 73598e8fb..92ea1bef2 100644 --- a/tests/units/Afup/Association/Cotisations.php +++ b/tests/units/Afup/Association/Cotisations.php @@ -27,8 +27,8 @@ protected function generateCotisationProvider() ], [ 'case' => 'La cotisation précédente expire dans 1 mois, la nouvelle cotisation doit expirer dans 13 mois', - 'date_fin' => (new \DateTime('+1 month')), - 'expected' => (new \DateTime('+1 month'))->add(new \DateInterval('P1Y')), + 'date_fin' => (new \DateTimeImmutable('+1 month'))->setTime(14, 0), + 'expected' => (new \DateTimeImmutable('+1 month'))->setTime(14, 0)->add(new \DateInterval('P1Y')), ], ]; }