simplify code with http.Flusher type conversion (#325)
* simplify code with http.Flusher type conversion * simplify code with http.Flusher type conversion, better version
This commit is contained in:
@@ -21,7 +21,7 @@ func TestWithCodeResponseWriter(t *testing.T) {
|
||||
assert.Nil(t, err)
|
||||
|
||||
flusher, ok := http.ResponseWriter(cw).(http.Flusher)
|
||||
assert.Equal(t, ok, true)
|
||||
assert.True(t, ok)
|
||||
flusher.Flush()
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user