(t testing.TB)
| 18 | } |
| 19 | |
| 20 | func NewTestingLogger(t testing.TB) *TestingLogger { |
| 21 | logger := &TestingLogger{ |
| 22 | t: t, |
| 23 | mtx: &sync.Mutex{}, |
| 24 | } |
| 25 | registerCleanup(t, logger) |
| 26 | return logger |
| 27 | } |
| 28 | |
| 29 | // WithT returns a new logger that logs to t. Writes between the new logger and the original logger are synchronized. |
| 30 | func (l *TestingLogger) WithT(t testing.TB) log.Logger { |