mirror of
https://github.com/labstack/echo.git
synced 2024-12-22 20:06:21 +02:00
acc91b28f3
* Improve test coverage * add engine package to coverage profile
25 lines
538 B
Go
25 lines
538 B
Go
package fasthttp
|
|
|
|
import (
|
|
"github.com/labstack/echo/engine/test"
|
|
"github.com/stretchr/testify/assert"
|
|
fast "github.com/valyala/fasthttp"
|
|
"testing"
|
|
)
|
|
|
|
func TestRequestHeader(t *testing.T) {
|
|
header := &RequestHeader{&fast.RequestHeader{}}
|
|
test.HeaderTest(t, header)
|
|
|
|
header.reset(&fast.RequestHeader{})
|
|
assert.Len(t, header.Keys(), 0)
|
|
}
|
|
|
|
func TestResponseHeader(t *testing.T) {
|
|
header := &ResponseHeader{&fast.ResponseHeader{}}
|
|
test.HeaderTest(t, header)
|
|
|
|
header.reset(&fast.ResponseHeader{})
|
|
assert.Len(t, header.Keys(), 1)
|
|
}
|