mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
Fix phpunit tests
This commit is contained in:
@@ -26,6 +26,7 @@ namespace Tests\integration\Support\Models;
|
||||
|
||||
use Carbon\Carbon;
|
||||
use FireflyIII\Support\Models\BillDateCalculator;
|
||||
use PHPUnit\Framework\Attributes\DataProvider;
|
||||
use Tests\integration\TestCase;
|
||||
|
||||
/**
|
||||
@@ -37,19 +38,21 @@ use Tests\integration\TestCase;
|
||||
*/
|
||||
final class BillDateCalculatorTest extends TestCase
|
||||
{
|
||||
private readonly BillDateCalculator $calculator;
|
||||
private BillDateCalculator $calculator;
|
||||
|
||||
public function __construct(string $name)
|
||||
|
||||
public function setUp(): void
|
||||
{
|
||||
parent::__construct($name);
|
||||
parent::setUp();
|
||||
$this->calculator = new BillDateCalculator();
|
||||
}
|
||||
|
||||
/**
|
||||
* Stupid long method names I'm not going to do that.
|
||||
*
|
||||
* @dataProvider provideDates
|
||||
*
|
||||
*/
|
||||
#[DataProvider('provideDates')]
|
||||
public function testGivenSomeDataItWorks(Carbon $earliest, Carbon $latest, Carbon $billStart, string $period, int $skip, ?Carbon $lastPaid, array $expected): void
|
||||
{
|
||||
$result = $this->calculator->getPayDates($earliest, $latest, $billStart, $period, $skip, $lastPaid);
|
||||
|
@@ -35,10 +35,6 @@ use Tests\integration\TestCase;
|
||||
*/
|
||||
final class NavigationCustomEndOfPeriodTest extends TestCase
|
||||
{
|
||||
public function __construct(string $name)
|
||||
{
|
||||
parent::__construct($name);
|
||||
}
|
||||
|
||||
/**
|
||||
* @preserveGlobalState disabled
|
||||
|
Reference in New Issue
Block a user