Fixed tests

This commit is contained in:
Eduard Urbach 2019-06-02 12:30:25 +09:00
parent 4d919ef752
commit 36427a1501
Signed by: akyoto
GPG Key ID: C874F672B1AF20C0

View File

@ -4,6 +4,7 @@ import (
"fmt"
"net/http"
"net/http/httptest"
"strings"
"testing"
"github.com/aerogo/aero"
@ -111,7 +112,7 @@ func TestQuotePages(t *testing.T) {
// }
func testRoute(t *testing.T, app *aero.Application, route string) {
request := httptest.NewRequest("GET", route, nil)
request := httptest.NewRequest("GET", strings.ReplaceAll(route, " ", "%20"), nil)
response := httptest.NewRecorder()
app.ServeHTTP(response, request)
status := response.Code