Skip to content

Commit

Permalink
added comments to the tests function and fix some typo
Browse files Browse the repository at this point in the history
  • Loading branch information
lafriakh committed Feb 4, 2019
1 parent 4f6ef8b commit 054aaef
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/kira_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import (
"github.com/go-kira/kira"
)

// Create a server with initial routes.
func setupServer() *httptest.Server {
app := kira.New()

Expand All @@ -31,6 +32,8 @@ func setupServer() *httptest.Server {

return ts
}

// Test against GET requests.
func getResponse(path string) ([]byte, error) {
ts := setupServer()
defer ts.Close()
Expand Down Expand Up @@ -78,7 +81,7 @@ func TestTemplateNotExists(t *testing.T) {
}

// Assert
if fmt.Sprintf("%s", content) != "not existss" {
t.Errorf("The response is not equal to: `Kira Template`, is equal to: %s", content)
if fmt.Sprintf("%s", content) != "not exists" {
t.Errorf("The response is not equal to: `not exists`, is equal to: %s", content)
}
}

0 comments on commit 054aaef

Please sign in to comment.