diff options
author | Franck Cuny <franck@lumberjaph.net> | 2013-05-11 15:18:52 -0700 |
---|---|---|
committer | Franck Cuny <franck@lumberjaph.net> | 2013-05-11 15:18:52 -0700 |
commit | 1a5bbf79c0088091876fc329aef05baf85d88f8d (patch) | |
tree | ae5e337863a33fbf358f0c1d770e5da55b399d37 /router_benchmark_test.go | |
parent | remove the example, it does not make sense anymore (diff) | |
download | path-router-1a5bbf79c0088091876fc329aef05baf85d88f8d.tar.gz |
The response object is passed to the matching function.
Instead of letting the matching function creates the response object, it's created earlier with a default HTTP status of 200, and the object is passed to the function.
Diffstat (limited to 'router_benchmark_test.go')
-rw-r--r-- | router_benchmark_test.go | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/router_benchmark_test.go b/router_benchmark_test.go index 42fe579..222b72e 100644 --- a/router_benchmark_test.go +++ b/router_benchmark_test.go @@ -8,9 +8,8 @@ import ( "testing" ) -func testSimpleRoute(req *request.Request) (request.Response, error) { - resp := request.Response{} - return resp, nil +func testSimpleRoute(req *request.Request, resp *request.Response) error { + return nil } func BenchmarkSimple(b *testing.B) { |