(t *testing.T)
| 145 | } |
| 146 | |
| 147 | func TestErrorfWrapErrorf(t *testing.T) { |
| 148 | wrapped := Errorf("wrapped string = %s, wrapped safe string = %s", "sensitive", Safe("safe")) |
| 149 | err := Errorf("error: %w", wrapped) |
| 150 | checkUnredactedError(t, err, "error: wrapped string = sensitive, wrapped safe string = safe") |
| 151 | checkRedactedError(t, err, "error: wrapped string = <redacted string>, wrapped safe string = safe") |
| 152 | } |
| 153 | |
| 154 | func TestErrorfAs(t *testing.T) { |
| 155 | wrapped := &customError{ |
nothing calls this directly
no test coverage detected