Skip to content

Commit

Permalink
tests: fix assertions on default serializers
Browse files Browse the repository at this point in the history
  • Loading branch information
gerardolima committed Nov 12, 2024
1 parent bbbecc3 commit 054993b
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions test/serializers.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,9 @@ test('child does not overwrite parent serializers', async ({ equal }) => {
test('Symbol.for(\'pino.serializers\')', async ({ equal, same, not }) => {
const stream = sink()
const expected = Object.assign({
err: stdSerializers.err
err: stdSerializers.err,
req: stdSerializers.req,
res: stdSerializers.res
}, parentSerializers)
const parent = pino({ serializers: parentSerializers }, stream)
const child = parent.child({ a: 'property' })
Expand Down Expand Up @@ -158,7 +160,9 @@ test('children inherit parent Symbol serializers', async ({ equal, same, not })
[Symbol.for('b')]: b
}
const expected = Object.assign({
err: stdSerializers.err
err: stdSerializers.err,
req: stdSerializers.req,
res: stdSerializers.res
}, symbolSerializers)
const parent = pino({ serializers: symbolSerializers }, stream)

Expand Down

0 comments on commit 054993b

Please sign in to comment.