Skip to content

Commit

Permalink
Test Err.
Browse files Browse the repository at this point in the history
  • Loading branch information
westy92 committed May 8, 2024
1 parent eb17c42 commit 7e5c724
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion holidays_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import (
"github.com/stretchr/testify/assert"
)

var ErrTest = errors.New("err")

func TestNew(t *testing.T) {
t.Parallel()
t.Run("fails with missing API Key", func(t *testing.T) {
Expand Down Expand Up @@ -133,7 +135,7 @@ func TestCommonFunctionality(t *testing.T) {
defer gock.Off()
gock.New("https://api.apilayer.com/checkiday/").
Get("/events").
ReplyError(errors.New("err"))
ReplyError(ErrTest)

api, _ := New(APILayer, "abc123")
response, err := api.GetEvents(GetEventsRequest{})
Expand Down

0 comments on commit 7e5c724

Please sign in to comment.