remove debug print statements from test code (#1540)
Found using https://go-critic.github.io/overview#commentedOutCode-ref
This commit is contained in:
parent
500ebd9ea8
commit
df1e17c2f0
11
tree_test.go
11
tree_test.go
@ -125,8 +125,6 @@ func TestTreeAddAndGet(t *testing.T) {
|
|||||||
tree.addRoute(route, fakeHandler(route))
|
tree.addRoute(route, fakeHandler(route))
|
||||||
}
|
}
|
||||||
|
|
||||||
//printChildren(tree, "")
|
|
||||||
|
|
||||||
checkRequests(t, tree, testRequests{
|
checkRequests(t, tree, testRequests{
|
||||||
{"/a", false, "/a", nil},
|
{"/a", false, "/a", nil},
|
||||||
{"/", true, "", nil},
|
{"/", true, "", nil},
|
||||||
@ -168,8 +166,6 @@ func TestTreeWildcard(t *testing.T) {
|
|||||||
tree.addRoute(route, fakeHandler(route))
|
tree.addRoute(route, fakeHandler(route))
|
||||||
}
|
}
|
||||||
|
|
||||||
//printChildren(tree, "")
|
|
||||||
|
|
||||||
checkRequests(t, tree, testRequests{
|
checkRequests(t, tree, testRequests{
|
||||||
{"/", false, "/", nil},
|
{"/", false, "/", nil},
|
||||||
{"/cmd/test/", false, "/cmd/:tool/", Params{Param{"tool", "test"}}},
|
{"/cmd/test/", false, "/cmd/:tool/", Params{Param{"tool", "test"}}},
|
||||||
@ -208,7 +204,6 @@ func TestUnescapeParameters(t *testing.T) {
|
|||||||
tree.addRoute(route, fakeHandler(route))
|
tree.addRoute(route, fakeHandler(route))
|
||||||
}
|
}
|
||||||
|
|
||||||
//printChildren(tree, "")
|
|
||||||
unescape := true
|
unescape := true
|
||||||
checkRequests(t, tree, testRequests{
|
checkRequests(t, tree, testRequests{
|
||||||
{"/", false, "/", nil},
|
{"/", false, "/", nil},
|
||||||
@ -260,8 +255,6 @@ func testRoutes(t *testing.T, routes []testRoute) {
|
|||||||
t.Errorf("unexpected panic for route '%s': %v", route.path, recv)
|
t.Errorf("unexpected panic for route '%s': %v", route.path, recv)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//printChildren(tree, "")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestTreeWildcardConflict(t *testing.T) {
|
func TestTreeWildcardConflict(t *testing.T) {
|
||||||
@ -328,8 +321,6 @@ func TestTreeDupliatePath(t *testing.T) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//printChildren(tree, "")
|
|
||||||
|
|
||||||
checkRequests(t, tree, testRequests{
|
checkRequests(t, tree, testRequests{
|
||||||
{"/", false, "/", nil},
|
{"/", false, "/", nil},
|
||||||
{"/doc/", false, "/doc/", nil},
|
{"/doc/", false, "/doc/", nil},
|
||||||
@ -444,8 +435,6 @@ func TestTreeTrailingSlashRedirect(t *testing.T) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//printChildren(tree, "")
|
|
||||||
|
|
||||||
tsrRoutes := [...]string{
|
tsrRoutes := [...]string{
|
||||||
"/hi/",
|
"/hi/",
|
||||||
"/b",
|
"/b",
|
||||||
|
Loading…
Reference in New Issue
Block a user