diff --git a/composer.json b/composer.json index 068ef756..acc66427 100644 --- a/composer.json +++ b/composer.json @@ -90,7 +90,7 @@ "phpunit --colors --testsuite=unit" ], "infection": [ - "./bin/infection --threads=8 --min-msi=98 --show-mutations" + "./bin/infection --threads=8 --min-msi=100 --show-mutations" ], "tests": [ "@tests:unit" diff --git a/tests/unit/DateTest.php b/tests/unit/DateTest.php index 25049e8e..62ae1d5d 100644 --- a/tests/unit/DateTest.php +++ b/tests/unit/DateTest.php @@ -416,7 +416,9 @@ public function it_can_be_offset_by_days(int $days): void $expectedDate = Date::fromDateTime($date->startOfDay()->modify(\sprintf('%d days', $days))); - if ($days !== 0) { + if ($days === 0) { + $this->assertSame($date, $offsetDate); + } else { $this->assertNotSame($date, $offsetDate); } @@ -447,7 +449,9 @@ public function it_can_be_offset_by_months(int $days): void $expectedDate = Date::fromDateTime($date->startOfDay()->modify(\sprintf('%d months', $days))); - if ($days !== 0) { + if ($days === 0) { + $this->assertSame($date, $offsetDate); + } else { $this->assertNotSame($date, $offsetDate); } @@ -478,7 +482,9 @@ public function it_can_be_offset_by_years(int $days): void $expectedDate = Date::fromDateTime($date->startOfDay()->modify(\sprintf('%d years', $days))); - if ($days !== 0) { + if ($days === 0) { + $this->assertSame($date, $offsetDate); + } else { $this->assertNotSame($date, $offsetDate); }