MockResponse::make(['score' => 'LOW_RISK'], 200), ]); $config = createTestConfig(); $connector = new AlfaBankConnector($config); $connector->withMockClient($mockClient); $response = $connector->send(new GetComplianceScoreRequest('7700000000')); expect($response->status())->toBe(200) ->and($response->json('score'))->toBe('LOW_RISK'); }); test('can get security subscriptions', function () { $mockClient = new \Saloon\Http\Faking\MockClient([ GetSubscriptionsRequest::class => MockResponse::make(['subscriptions' => []], 200), ]); $config = createTestConfig(); $connector = new AlfaBankConnector($config); $connector->withMockClient($mockClient); $response = $connector->send(new GetSubscriptionsRequest()); expect($response->status())->toBe(200); });