Skip to content

Commit

Permalink
fix: add body to tests
Browse files Browse the repository at this point in the history
  • Loading branch information
nobe4 committed Jan 2, 2025
1 parent 20dfb5e commit 19ab455
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions internal/actions/assign/assign_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ package assign
import (
"bytes"
"errors"
"io"
"net/http"
"strings"
"testing"

"github.com/nobe4/gh-not/internal/api/mock"
Expand Down Expand Up @@ -72,7 +74,7 @@ func TestRun(t *testing.T) {
Verb: "POST",
URL: "https://api.github.com/repos/owner/repo/issues/123/assignees",
Data: `{"assignees":["user"]}`,
Response: &http.Response{StatusCode: http.StatusCreated},
Response: &http.Response{StatusCode: http.StatusCreated, Body: io.NopCloser(strings.NewReader(""))},
})
n := &notifications.Notification{
Subject: notifications.Subject{
Expand All @@ -94,7 +96,7 @@ func TestRun(t *testing.T) {
Verb: "POST",
URL: "https://api.github.com/repos/owner/repo/issues/123/assignees",
Data: `{"assignees":["user"]}`,
Response: &http.Response{StatusCode: http.StatusCreated},
Response: &http.Response{StatusCode: http.StatusCreated, Body: io.NopCloser(strings.NewReader(""))},
})
n := &notifications.Notification{
Subject: notifications.Subject{
Expand Down

0 comments on commit 19ab455

Please sign in to comment.