(t *testing.T)
| 26 | } |
| 27 | |
| 28 | func TestRedact(t *testing.T) { |
| 29 | backend := InitForTesting(DEBUG) |
| 30 | password := Password("123456") |
| 31 | log := MustGetLogger("test") |
| 32 | log.Debug("foo", password) |
| 33 | if "foo ******" != MemoryRecordN(backend, 0).Formatted(0) { |
| 34 | t.Errorf("redacted line: %v", MemoryRecordN(backend, 0)) |
| 35 | } |
| 36 | } |
| 37 | |
| 38 | func TestRedactf(t *testing.T) { |
| 39 | backend := InitForTesting(DEBUG) |
nothing calls this directly
no test coverage detected