mirror of
https://github.com/yusing/godoxy.git
synced 2026-04-23 17:28:53 +02:00
cleanup and simplify middleware implementations, refactor some other code
This commit is contained in:
@@ -46,7 +46,7 @@ func TestModifyResponse(t *testing.T) {
|
||||
}
|
||||
|
||||
t.Run("set_options", func(t *testing.T) {
|
||||
mr, err := ModifyResponse.WithOptionsClone(opts)
|
||||
mr, err := ModifyResponse.New(opts)
|
||||
ExpectNoError(t, err)
|
||||
ExpectDeepEqual(t, mr.impl.(*modifyResponse).SetHeaders, opts["set_headers"].(map[string]string))
|
||||
ExpectDeepEqual(t, mr.impl.(*modifyResponse).AddHeaders, opts["add_headers"].(map[string]string))
|
||||
|
||||
Reference in New Issue
Block a user