Skip to content

Commit

Permalink
This fixes the test coz I forgot to run the tests first
Browse files Browse the repository at this point in the history
  • Loading branch information
BarryCarlyon committed Jul 2, 2024
1 parent 106051e commit 5b3a96d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 0 additions & 1 deletion cmd/events/retrigger.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"fmt"
"time"

"github.com/fatih/color"
"github.com/spf13/cobra"
configure_event "github.com/twitchdev/twitch-cli/internal/events/configure"
"github.com/twitchdev/twitch-cli/internal/events/trigger"
Expand Down
6 changes: 5 additions & 1 deletion internal/events/trigger/retrigger_event_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import (

"github.com/twitchdev/twitch-cli/internal/models"
"github.com/twitchdev/twitch-cli/test_setup"
"github.com/twitchdev/twitch-cli/internal/util"
)

func TestRefireEvent(t *testing.T) {
Expand All @@ -24,8 +25,11 @@ func TestRefireEvent(t *testing.T) {
}))
defer ts.Close()

var eventMessageID = util.RandomGUID();

params := TriggerParameters{
Event: "gift",
EventMessageID: eventMessageID,
Transport: models.TransportWebhook,
IsAnonymous: false,
FromUser: "",
Expand All @@ -47,7 +51,7 @@ func TestRefireEvent(t *testing.T) {
err = json.Unmarshal([]byte(response), &body)
a.Nil(err)

json, err := RefireEvent(body.Subscription.ID, params)
json, err := RefireEvent(eventMessageID, params)
a.Nil(err)
a.Equal(response, json)
}

0 comments on commit 5b3a96d

Please sign in to comment.