refactor: align framework cleanup with new bootstrap flow
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
This commit is contained in:
@@ -36,17 +36,8 @@ func BenchmarkSuccess(b *testing.B) {
|
||||
})
|
||||
}
|
||||
|
||||
// BenchmarkError 测试错误响应性能
|
||||
func BenchmarkError(b *testing.B) {
|
||||
app := fiber.New()
|
||||
|
||||
b.ResetTimer()
|
||||
for i := 0; i < b.N; i++ {
|
||||
ctx := app.AcquireCtx(&fasthttp.RequestCtx{})
|
||||
_ = Error(ctx, 400, 1001, "无效的请求")
|
||||
app.ReleaseCtx(ctx)
|
||||
}
|
||||
}
|
||||
// BenchmarkError 基准测试已被删除 - Error() 函数已在重构中移除
|
||||
// 错误响应现在由全局 ErrorHandler 统一处理
|
||||
|
||||
// BenchmarkSuccessWithMessage 测试带自定义消息的成功响应性能
|
||||
func BenchmarkSuccessWithMessage(b *testing.B) {
|
||||
|
||||
Reference in New Issue
Block a user