feat(portfolio): store and publish instrument sector and issuer (WealthLedger/main#48) (#148)
This commit was merged in pull request #148.
This commit is contained in:
@@ -236,6 +236,16 @@ describe('TbankClient metadata retries', () => {
|
||||
jest.useRealTimers();
|
||||
});
|
||||
|
||||
it.each([
|
||||
['bondBy', (client: TbankClient, optIn: boolean) => client.getBond('token', 'uid', undefined, optIn)],
|
||||
['etfBy', (client: TbankClient, optIn: boolean) => client.getEtf('token', 'uid', undefined, optIn)],
|
||||
['getAssetBy', (client: TbankClient, optIn: boolean) => optIn ? client.getAssetBrand('token', 'uid') : client.getAssetDescription('token', 'uid')],
|
||||
])('%s reports NOT_FOUND only for classification lookups', async (_method, invoke) => {
|
||||
requestRpc.mockRejectedValue({ code: status.NOT_FOUND });
|
||||
await expect(invoke(client, false)).rejects.toBeInstanceOf(ServiceUnavailableException);
|
||||
await expect(invoke(client, true)).rejects.toBeInstanceOf(NotFoundException);
|
||||
});
|
||||
|
||||
it.each([
|
||||
status.UNAVAILABLE,
|
||||
status.DEADLINE_EXCEEDED,
|
||||
|
||||
Reference in New Issue
Block a user