mirror of
https://github.com/fluxcd/flagger.git
synced 2026-04-15 06:57:34 +00:00
replace ioutil in testing of gchat
Signed-off-by: DiptoChakrabarty <diptochuck123@gmail.com>
This commit is contained in:
committed by
DiptoChakrabarty
parent
2dacf08c30
commit
0bb3815f73
@@ -18,7 +18,7 @@ package notifier
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"io/ioutil"
|
||||
"io"
|
||||
"net/http"
|
||||
"net/http/httptest"
|
||||
"testing"
|
||||
@@ -34,7 +34,7 @@ func TestGChat_Post(t *testing.T) {
|
||||
}
|
||||
|
||||
ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
b, err := ioutil.ReadAll(r.Body)
|
||||
b, err := io.ReadAll(r.Body)
|
||||
require.NoError(t, err)
|
||||
|
||||
var payload = GChatPayload{}
|
||||
|
||||
Reference in New Issue
Block a user