Skip to content

Commit

Permalink
fix: retry flaky test (#3992)
Browse files Browse the repository at this point in the history
  • Loading branch information
metcoder95 authored Jan 9, 2025
1 parent e1496cf commit de6ec47
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions test/interceptors/retry.js
Original file line number Diff line number Diff line change
Expand Up @@ -562,14 +562,13 @@ test('should not error if request is not meant to be retried', async t => {
})

test('#3975 - keep event loop ticking', async t => {
const suite = tspl(t, { plan: 3 })
const suite = tspl(t, { plan: 2 })

const res = spawnSync('node', ['./test/fixtures/interceptors/retry-event-loop.js'], {
stdio: 'pipe'
})

const output = res.stderr.toString()
suite.ok(output.includes("code: 'UND_ERR_REQ_RETRY'"))
suite.ok(output.includes('UND_ERR_REQ_RETRY'))
suite.ok(output.includes('RequestRetryError: Request failed'))
suite.ok(output.includes('statusCode: 418'))
})

0 comments on commit de6ec47

Please sign in to comment.