Fix flaky client/rest/general/ping test (#8533)
This commit is contained in:
parent
8fae132afa
commit
0bac4b96f0
1 changed files with 2 additions and 2 deletions
|
|
@ -22,12 +22,12 @@ describe('ClientGeneral', () => {
|
|||
const deviceId = 'device1';
|
||||
const timeoutInterval = 1000;
|
||||
const groupLabel = 'DeepLink';
|
||||
const expectedUrl = `${client.urlVersion}/system/ping?time=${Date.now()}&device_id=${deviceId}`;
|
||||
const expectedUrl = `${client.urlVersion}/system/ping`;
|
||||
const expectedOptions = {method: 'get', timeoutInterval, groupLabel};
|
||||
|
||||
await client.ping(deviceId, timeoutInterval, groupLabel);
|
||||
|
||||
expect(client.doFetch).toHaveBeenCalledWith(expectedUrl, expectedOptions, false);
|
||||
expect(client.doFetch).toHaveBeenCalledWith(expect.stringContaining(expectedUrl), expectedOptions, false);
|
||||
});
|
||||
|
||||
test('logClientError', async () => {
|
||||
|
|
|
|||
Loading…
Reference in a new issue