Skip to content

Commit

Permalink
Add getQueue() tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexandr Borisov authored and aishek committed Jun 10, 2024
1 parent 12f431d commit 4d2fed8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions __tests__/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,12 @@ it('support dynamic options', async function () {
}
await delay(90)
expect(onSuccess.callCount).toEqual(2)
expect(http.getQueue().length).toEqual(1)

await Promise.all(requests)
var end = Date.now()
expect(onSuccess.callCount).toEqual(3)
expect(http.getQueue().length).toEqual(0)
expect(end - start).toBeGreaterThan(100)
await delay(110)

Expand Down

0 comments on commit 4d2fed8

Please sign in to comment.