浏览代码

remove debug print statements from test code (#1540)

Found using https://go-critic.github.io/overview#commentedOutCode-ref
Iskander (Alex) Sharipov 7 年之前
父节点
当前提交
df1e17c2f0
共有 1 个文件被更改,包括 0 次插入11 次删除
  1. 0 11
      tree_test.go

+ 0 - 11
tree_test.go

@@ -125,8 +125,6 @@ func TestTreeAddAndGet(t *testing.T) {
 		tree.addRoute(route, fakeHandler(route))
 	}
 
-	//printChildren(tree, "")
-
 	checkRequests(t, tree, testRequests{
 		{"/a", false, "/a", nil},
 		{"/", true, "", nil},
@@ -168,8 +166,6 @@ func TestTreeWildcard(t *testing.T) {
 		tree.addRoute(route, fakeHandler(route))
 	}
 
-	//printChildren(tree, "")
-
 	checkRequests(t, tree, testRequests{
 		{"/", false, "/", nil},
 		{"/cmd/test/", false, "/cmd/:tool/", Params{Param{"tool", "test"}}},
@@ -208,7 +204,6 @@ func TestUnescapeParameters(t *testing.T) {
 		tree.addRoute(route, fakeHandler(route))
 	}
 
-	//printChildren(tree, "")
 	unescape := true
 	checkRequests(t, tree, testRequests{
 		{"/", false, "/", nil},
@@ -260,8 +255,6 @@ func testRoutes(t *testing.T, routes []testRoute) {
 			t.Errorf("unexpected panic for route '%s': %v", route.path, recv)
 		}
 	}
-
-	//printChildren(tree, "")
 }
 
 func TestTreeWildcardConflict(t *testing.T) {
@@ -328,8 +321,6 @@ func TestTreeDupliatePath(t *testing.T) {
 		}
 	}
 
-	//printChildren(tree, "")
-
 	checkRequests(t, tree, testRequests{
 		{"/", false, "/", nil},
 		{"/doc/", false, "/doc/", nil},
@@ -444,8 +435,6 @@ func TestTreeTrailingSlashRedirect(t *testing.T) {
 		}
 	}
 
-	//printChildren(tree, "")
-
 	tsrRoutes := [...]string{
 		"/hi/",
 		"/b",