(B *testing.B)
| 107 | } |
| 108 | |
| 109 | func Benchmark404Many(B *testing.B) { |
| 110 | router := New() |
| 111 | router.GET("/", func(c *Context) {}) |
| 112 | router.GET("/path/to/something", func(c *Context) {}) |
| 113 | router.GET("/post/:id", func(c *Context) {}) |
| 114 | router.GET("/view/:id", func(c *Context) {}) |
| 115 | router.GET("/favicon.ico", func(c *Context) {}) |
| 116 | router.GET("/robots.txt", func(c *Context) {}) |
| 117 | router.GET("/delete/:id", func(c *Context) {}) |
| 118 | router.GET("/user/:id/:mode", func(c *Context) {}) |
| 119 | |
| 120 | router.NoRoute(func(c *Context) {}) |
| 121 | runRequest(B, router, http.MethodGet, "/viewfake") |
| 122 | } |
| 123 | |
| 124 | type mockWriter struct { |
| 125 | headers http.Header |
nothing calls this directly
no test coverage detected