Skip to content

Commit

Permalink
test(unit): change the basis for failed test
Browse files Browse the repository at this point in the history
This is due to relaxation of text validation rules.
  • Loading branch information
KennethTrecy committed Aug 10, 2024
1 parent c1b556b commit 0df6a6a
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions t/Feature/Resource/FinancialEntryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -568,8 +568,7 @@ public function testInvalidCreate()
$modifier = $modifier_fabricator->create();
$financial_entry_fabricator = new Fabricator(FinancialEntryModel::class);
$financial_entry_fabricator->setOverrides([
"modifier_id" => $modifier->id,
"remarks" => "@ characters not allowed here"
"modifier_id" => $modifier->id + 1
]);
$financial_entry = $financial_entry_fabricator->make();

Expand Down Expand Up @@ -780,14 +779,13 @@ public function testInvalidUpdate()
$modifier = $modifier_fabricator->create();
$financial_entry_fabricator = new Fabricator(FinancialEntryModel::class);
$financial_entry_fabricator->setOverrides([
"modifier_id" => $modifier->id,
"remarks" => "@ characters not allowed here"
"modifier_id" => $modifier->id + 1
]);
$financial_entry = $financial_entry_fabricator->create();
$new_details = $financial_entry_fabricator->make();

$this->expectException(InvalidRequest::class);
$this->expectExceptionCode(400);
$this->expectException(MissingResource::class);
$this->expectExceptionCode(404);
$result = $authenticated_info
->getRequest()
->withBodyFormat("json")
Expand Down

0 comments on commit 0df6a6a

Please sign in to comment.