TestTreeRootTrailingSlashRedirect() — gin Function Reference
Architecture documentation for the TestTreeRootTrailingSlashRedirect() function in tree_test.go from the gin codebase.
Entity Profile
Dependency Diagram
graph TD 88232784_e360_10cf_0f68_76f67233eaa8["TestTreeRootTrailingSlashRedirect()"] 7d17d111_6d55_8539_e0ed_b32eea9e5ef6["catchPanic()"] 88232784_e360_10cf_0f68_76f67233eaa8 -->|calls| 7d17d111_6d55_8539_e0ed_b32eea9e5ef6 6dab8d3e_0986_1500_b06f_6323ea7ce91a["fakeHandler()"] 88232784_e360_10cf_0f68_76f67233eaa8 -->|calls| 6dab8d3e_0986_1500_b06f_6323ea7ce91a 3890ddc0_c7b9_b8d1_7ac9_5fc2030c1b8e["getSkippedNodes()"] 88232784_e360_10cf_0f68_76f67233eaa8 -->|calls| 3890ddc0_c7b9_b8d1_7ac9_5fc2030c1b8e style 88232784_e360_10cf_0f68_76f67233eaa8 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
tree_test.go lines 676–692
func TestTreeRootTrailingSlashRedirect(t *testing.T) {
tree := &node{}
recv := catchPanic(func() {
tree.addRoute("/:test", fakeHandler("/:test"))
})
if recv != nil {
t.Fatalf("panic inserting test route: %v", recv)
}
value := tree.getValue("/", nil, getSkippedNodes(), false)
if value.handlers != nil {
t.Fatalf("non-nil handler")
} else if value.tsr {
t.Errorf("expected no TSR recommendation")
}
}
Domain
Subdomains
Source
Frequently Asked Questions
What does TestTreeRootTrailingSlashRedirect() do?
TestTreeRootTrailingSlashRedirect() is a function in the gin codebase.
What does TestTreeRootTrailingSlashRedirect() call?
TestTreeRootTrailingSlashRedirect() calls 3 function(s): catchPanic, fakeHandler, getSkippedNodes.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free