package main_test import ( "testing" "github.com/beego/beego/v2/server/web" "github.com/beego/beego/v2/server/web/context" ) func BenchmarkBeego(b *testing.B) { bench( b, func() *web.ControllerRegister { return web.NewControllerRegister() }, func(s *web.ControllerRegister, method string, path string) { s.AddMethod(method, path, func(ctx *context.Context) { ctx.Output.Body(payload) }) }, ) }