fix gitlab tests
This commit is contained in:
@@ -133,7 +133,7 @@ class AdditionalChargeTest extends TestCase
|
||||
'created_by' => null,
|
||||
]);
|
||||
|
||||
$model = new AdditionalCharge;
|
||||
$model = new AdditionalCharge();
|
||||
$result = $model->markApplied([$first->id, (string) $second->id], $invoiceId);
|
||||
|
||||
$this->assertTrue($result);
|
||||
@@ -173,7 +173,7 @@ class AdditionalChargeTest extends TestCase
|
||||
'created_by' => null,
|
||||
]);
|
||||
|
||||
$paginator = (new AdditionalCharge)->listAllForTerm('2024-2025', 'Spring', null, null, 50, true);
|
||||
$paginator = (new AdditionalCharge())->listAllForTerm('2024-2025', 'Spring', null, null, 50, true);
|
||||
|
||||
$this->assertSame(1, $paginator->total());
|
||||
$first = $paginator->items()[0];
|
||||
@@ -225,19 +225,19 @@ class AdditionalChargeTest extends TestCase
|
||||
'created_by' => null,
|
||||
]);
|
||||
|
||||
$paginator = (new AdditionalCharge)->listAllForTerm('2024-2025', 'Fall', null, 'Math', 50, true);
|
||||
$paginator = (new AdditionalCharge())->listAllForTerm('2024-2025', 'Fall', null, 'Math', 50, true);
|
||||
|
||||
$this->assertSame(1, $paginator->total());
|
||||
$this->assertSame('Math Club Fee', $paginator->items()[0]->title);
|
||||
|
||||
$byDescription = (new AdditionalCharge)->listAllForTerm('2024-2025', 'Fall', null, 'enrichment', 50, true);
|
||||
$byDescription = (new AdditionalCharge())->listAllForTerm('2024-2025', 'Fall', null, 'enrichment', 50, true);
|
||||
$this->assertSame(1, $byDescription->total());
|
||||
$this->assertSame('Math Club Fee', $byDescription->items()[0]->title);
|
||||
|
||||
$byParentName = (new AdditionalCharge)->listAllForTerm('2024-2025', 'Fall', null, 'Hassan', 50, true);
|
||||
$byParentName = (new AdditionalCharge())->listAllForTerm('2024-2025', 'Fall', null, 'Hassan', 50, true);
|
||||
$this->assertSame(2, $byParentName->total());
|
||||
|
||||
$byInvoice = (new AdditionalCharge)->listAllForTerm('2024-2025', 'Fall', null, 'INV-2025-001', 50, true);
|
||||
$byInvoice = (new AdditionalCharge())->listAllForTerm('2024-2025', 'Fall', null, 'INV-2025-001', 50, true);
|
||||
$this->assertSame(2, $byInvoice->total());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user