From 0c6b007f011011e2cca949ce30efba76414e5fd8 Mon Sep 17 00:00:00 2001 From: Artem Yadelskyi Date: Wed, 3 May 2023 23:52:23 +0300 Subject: [PATCH] Fixed tests & linters --- long_polling_test.go | 1 + webhook_test.go | 2 ++ 2 files changed, 3 insertions(+) diff --git a/long_polling_test.go b/long_polling_test.go index a703307..a4d0bbe 100644 --- a/long_polling_test.go +++ b/long_polling_test.go @@ -219,6 +219,7 @@ func TestWithLongPollingContext(t *testing.T) { }) t.Run("error", func(t *testing.T) { + //nolint:staticcheck err := WithLongPollingContext(nil)(lCtx) assert.Error(t, err) }) diff --git a/webhook_test.go b/webhook_test.go index f1f0af1..fca7793 100644 --- a/webhook_test.go +++ b/webhook_test.go @@ -205,6 +205,7 @@ func TestBot_UpdatesViaWebhook(t *testing.T) { update, ok := <-updates require.True(t, ok) + update.ctx = nil assert.Equal(t, expectedUpdate, update) @@ -355,6 +356,7 @@ func TestWithWebhookContext(t *testing.T) { }) t.Run("error", func(t *testing.T) { + //nolint:staticcheck err := WithWebhookContext(nil)(nil, wCtx) assert.Error(t, err) })