(t *testing.T)
| 358 | } |
| 359 | |
| 360 | func TestGzipResponseWriter_CanHijack(t *testing.T) { |
| 361 | trwu := testResponseWriterUnwrapperHijack{testResponseWriterUnwrapper: testResponseWriterUnwrapper{rw: httptest.NewRecorder()}} |
| 362 | bdrw := gzipResponseWriter{ |
| 363 | ResponseWriter: &trwu, // this RW supports hijacking through unwrapping |
| 364 | } |
| 365 | _, _, err := bdrw.Hijack() |
| 366 | assert.EqualError(t, err, "can hijack") |
| 367 | } |
| 368 | |
| 369 | func TestGzipResponseWriter_CanNotHijack(t *testing.T) { |
| 370 | trwu := testResponseWriterUnwrapper{rw: httptest.NewRecorder()} |
nothing calls this directly
no test coverage detected
searching dependent graphs…