Add failure for creation
This commit is contained in:
parent
90d91088a9
commit
1238309006
|
@ -20,6 +20,15 @@ class CourseFake extends Fake {
|
|||
});
|
||||
}
|
||||
|
||||
public function doesntCreateWithError(int $memberId): void
|
||||
{
|
||||
Http::fake(function($request) use ($memberId) {
|
||||
if ($request->url() === "https://nami.dpsg.de/ica/rest/nami/mitglied-ausbildung/filtered-for-navigation/mitglied/mitglied/{$memberId}") {
|
||||
return Http::response('{"success":false,"data":null,"responseType":"EXCEPTION","message":"Unexpected Error javax.ejb.EJBException","title":null}', 200);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $memberId
|
||||
* @param array<string, mixed> $payload
|
||||
|
|
Loading…
Reference in New Issue