From a13f46036acedb59202c9bf9e1c13337dfccfd4a Mon Sep 17 00:00:00 2001 From: Nic West Date: Tue, 1 Nov 2016 12:15:03 +0000 Subject: [PATCH] remove http method constants from tests --- webprofile_test.go | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/webprofile_test.go b/webprofile_test.go index ac795b2..0b654a2 100644 --- a/webprofile_test.go +++ b/webprofile_test.go @@ -16,32 +16,32 @@ type webprofileTestServer struct { func (ts *webprofileTestServer) ServeHTTP(w http.ResponseWriter, r *http.Request) { ts.t.Log(r.RequestURI) if r.RequestURI == "/v1/payment-experience/web-profiles" { - if r.Method == http.MethodPost { + if r.Method == "POST" { ts.create(w, r) } - if r.Method == http.MethodGet { + if r.Method == "GET" { ts.list(w, r) } } if r.RequestURI == "/v1/payment-experience/web-profiles/XP-CP6S-W9DY-96H8-MVN2" { - if r.Method == http.MethodGet { + if r.Method == "GET" { ts.getvalid(w, r) } - if r.Method == http.MethodPut { + if r.Method == "PUT" { ts.updatevalid(w, r) } - if r.Method == http.MethodDelete { + if r.Method == "DELETE" { ts.deletevalid(w, r) } } if r.RequestURI == "/v1/payment-experience/web-profiles/foobar" { - if r.Method == http.MethodGet { + if r.Method == "GET" { ts.getinvalid(w, r) } - if r.Method == http.MethodPut { + if r.Method == "PUT" { ts.updateinvalid(w, r) } - if r.Method == http.MethodDelete { + if r.Method == "DELETE" { ts.deleteinvalid(w, r) } }