1
0
mirror of https://github.com/labstack/echo.git synced 2025-07-15 01:34:53 +02:00

Added coverage for middleware

Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
Vishal Rana
2015-03-29 20:44:55 -07:00
parent bbafeb9abd
commit c29ae7dd7d
4 changed files with 59 additions and 11 deletions

View File

@ -17,7 +17,6 @@ type (
}
)
func (r *response) WriteHeader(n int) {
// TODO: fix when halted.
if r.committed {
@ -53,7 +52,7 @@ func (r *response) Flusher() {
func (r *response) Hijack() (net.Conn, *bufio.ReadWriter, error) {
h, ok := r.ResponseWriter.(http.Hijacker)
if !ok {
return nil, nil, errors.New("hijacker interface not supported")
return nil, nil, errors.New("bolt: hijacker interface not supported")
}
return h.Hijack()
}