File tree Expand file tree Collapse file tree
samples/server/petstore/go-api-server/samples_tests Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11package main
22
33import (
4- "testing"
54 "strings"
5+ "testing"
66
77 "github.com/GIT_USER_ID/GIT_REPO_ID/samples_tests/utils"
88)
@@ -14,8 +14,9 @@ func Test_Routers(t *testing.T) {
1414 filepath := "../go/routers.go"
1515
1616 expected := ("type Route struct {\n " +
17- "\t Method\t string\n " +
18- "\t Pattern\t string\n " +
17+ "\t Name string\n " +
18+ "\t Method string\n " +
19+ "\t Pattern string\n " +
1920 "\t HandlerFunc http.HandlerFunc\n " +
2021 "}" )
2122
@@ -31,8 +32,8 @@ func Test_Routers(t *testing.T) {
3132 lines := utils .ReadLines (filepath )
3233 expected := "type Routes map[string]Route"
3334
34- if lines [25 ] != expected {
35- t .Errorf ("Expected '%s', but got '%s'" , expected , lines [25 ])
35+ if lines [26 ] != expected {
36+ t .Errorf ("Expected '%s', but got '%s'" , expected , lines [26 ])
3637 }
3738 })
3839}
You can’t perform that action at this time.
0 commit comments