@@ -32,7 +32,7 @@ test('should subscribe to wrap-logger events and buffer them', async () => {
3232
3333 const message = faker . string . uuid ( )
3434 myLoggerSuite . myTestLogger ( message )
35- expect ( loggingUtilsModule . bufferLog ) . toHaveBeenCalledWith ( loggingInstrument . ee , message , customAttributes , 'error' )
35+ expect ( loggingUtilsModule . bufferLog ) . toHaveBeenCalledWith ( loggingInstrument . ee , message , customAttributes , 'error' , true )
3636} )
3737
3838test ( 'wrapLogger should not re-wrap or overwrite context if called more than once' , async ( ) => {
@@ -44,12 +44,12 @@ test('wrapLogger should not re-wrap or overwrite context if called more than onc
4444
4545 let message = faker . string . uuid ( )
4646 myLoggerSuite . myTestLogger ( message )
47- expect ( loggingUtilsModule . bufferLog ) . toHaveBeenCalledWith ( loggingInstrument . ee , message , customAttributes , 'error' ) // ignores args: 2
47+ expect ( loggingUtilsModule . bufferLog ) . toHaveBeenCalledWith ( loggingInstrument . ee , message , customAttributes , 'error' , true ) // ignores args: 2
4848
4949 const newCustomAttributes = { args : faker . string . uuid ( ) }
5050 /** re-wrap the logger with a NEW context, new events should NOT get that context because the wrapper should early-exit */
5151 wrapLogger ( loggingInstrument . ee , myLoggerSuite , 'myTestLogger' , { customAttributes : newCustomAttributes , level : 'info' } )
5252 message = faker . string . uuid ( )
5353 myLoggerSuite . myTestLogger ( message )
54- expect ( loggingUtilsModule . bufferLog ) . toHaveBeenCalledWith ( loggingInstrument . ee , message , newCustomAttributes , 'info' )
54+ expect ( loggingUtilsModule . bufferLog ) . toHaveBeenCalledWith ( loggingInstrument . ee , message , newCustomAttributes , 'info' , true )
5555} )
0 commit comments