🧪 Improve test formatting and fix spacing issues in api-client unit tests
This commit is contained in:
@@ -164,10 +164,10 @@ describe('api-client', () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
const promise = client.get('/retry');
|
const promise = client.get('/retry');
|
||||||
|
|
||||||
// Advance timers for retries
|
// Advance timers for retries
|
||||||
await vi.runAllTimersAsync();
|
await vi.runAllTimersAsync();
|
||||||
|
|
||||||
const result = await promise;
|
const result = await promise;
|
||||||
|
|
||||||
expect(result).toEqual({ success: true });
|
expect(result).toEqual({ success: true });
|
||||||
@@ -244,7 +244,9 @@ describe('api-client', () => {
|
|||||||
ok: true,
|
ok: true,
|
||||||
headers: new Headers({ 'content-type': 'application/json' }),
|
headers: new Headers({ 'content-type': 'application/json' }),
|
||||||
json: async () => ({}),
|
json: async () => ({}),
|
||||||
clone: function() { return this; }
|
clone: function () {
|
||||||
|
return this;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
await client.get('/test');
|
await client.get('/test');
|
||||||
|
|||||||
Reference in New Issue
Block a user