Skip to content

Commit

Permalink
Fix broken test (#1825)
Browse files Browse the repository at this point in the history
Co-authored-by: James Sumners <[email protected]>
  • Loading branch information
mcollina and jsumners authored Oct 4, 2023
1 parent a7ec2ca commit 3fb1413
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
"log": "^6.0.0",
"loglevel": "^1.6.7",
"midnight-smoker": "1.1.1",
"pino-pretty": "^10.0.0",
"pino-pretty": "^10.2.1",
"pre-commit": "^1.2.2",
"proxyquire": "^2.1.3",
"pump": "^3.0.0",
Expand Down
7 changes: 5 additions & 2 deletions test/multistream.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -221,16 +221,19 @@ test('supports pretty print', function (t) {
cb()
})

const nested = proxyquire('pino-pretty/lib/utils', {
const safeBoom = proxyquire('pino-pretty/lib/utils/build-safe-sonic-boom.js', {
'sonic-boom': function () {
t.pass('sonic created')
stream.flushSync = () => {}
stream.flush = () => {}
return stream
}
})
const nested = proxyquire('pino-pretty/lib/utils/index.js', {
'./build-safe-sonic-boom.js': safeBoom
})
const pretty = proxyquire('pino-pretty', {
'./lib/utils': nested
'./lib/utils/index.js': nested
})

const log = pino({
Expand Down

0 comments on commit 3fb1413

Please sign in to comment.