From f226b4cdf6466e88988f31b590e52d5e9cc5b0d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Arne=20J=C3=B8rgensen?= Date: Tue, 13 Feb 2024 10:50:53 +0100 Subject: [PATCH] Mark unsued parameters in tests as unused --- dsupdate_test.go | 2 +- post_test.go | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dsupdate_test.go b/dsupdate_test.go index c1664ff..cf56b3d 100644 --- a/dsupdate_test.go +++ b/dsupdate_test.go @@ -16,7 +16,7 @@ func TestDefaultBaseURL(t *testing.T) { func FuzzForm(f *testing.F) { f.Fuzz(func( - t *testing.T, + _ *testing.T, domain string, userID string, password string, diff --git a/post_test.go b/post_test.go index 47a06aa..75bab3e 100644 --- a/post_test.go +++ b/post_test.go @@ -24,7 +24,7 @@ func setup(status int, substatus dsupdate.SubStatus) (dsupdate.Client, func()) { mux := http.NewServeMux() server := httptest.NewServer(mux) - mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) { + mux.HandleFunc("/", func(w http.ResponseWriter, _ *http.Request) { if status == connectionClose { hj, _ := w.(http.Hijacker) conn, _, _ := hj.Hijack() @@ -62,7 +62,7 @@ func setupStatusOK() (dsupdate.Client, func()) { mux := http.NewServeMux() server := httptest.NewServer(mux) - mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) { + mux.HandleFunc("/", func(w http.ResponseWriter, _ *http.Request) { w.Header().Set("Content-Type", "text/plain") _, _ = w.Write([]byte("Request sent to DSU::Version_1_0 okay")) }) @@ -83,7 +83,7 @@ func setupSubStatus(substatus dsupdate.SubStatus) (dsupdate.Client, func()) { mux := http.NewServeMux() server := httptest.NewServer(mux) - mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) { + mux.HandleFunc("/", func(w http.ResponseWriter, _ *http.Request) { w.Header().Set("Content-Type", "text/plain") w.Header().Set("X-DSU", strconv.Itoa(int(substatus)))