From af2f5654659b83d66ccb7d03108ede615bdc57e5 Mon Sep 17 00:00:00 2001 From: Jim Myhrberg Date: Mon, 21 Mar 2022 18:16:12 +0000 Subject: [PATCH] chore!: remove deprecated Is() function, use Eq() instead --- gomockctx.go | 12 ------------ gomockctx_test.go | 4 ---- 2 files changed, 16 deletions(-) diff --git a/gomockctx.go b/gomockctx.go index f5ef8c9..b9d510a 100644 --- a/gomockctx.go +++ b/gomockctx.go @@ -59,18 +59,6 @@ func Eq(ctx context.Context) gomock.Matcher { return WithValue(ctxKey, getValue(ctx)) } -// Is accepts a context with a gomockctx ID value (as returned from New), and -// returns a gomock.Matcher which returns true for the given context, and any -// child contexts of it. -// -// If ctx was not returned from New, the resulting matcher will ALWAYS return -// false. -// -// Deprecated: Renamed to Eq(). -func Is(ctx context.Context) gomock.Matcher { - return Eq(ctx) -} - // ID returns the gomockctx ID value in the given context, or a empty string if // the context does not have a gomockctx ID value. func ID(ctx context.Context) string { diff --git a/gomockctx_test.go b/gomockctx_test.go index f3cb351..aafe826 100644 --- a/gomockctx_test.go +++ b/gomockctx_test.go @@ -109,10 +109,6 @@ func TestEq(t *testing.T) { } } -func TestIs(t *testing.T) { - TestEq(t) -} - func TestID(t *testing.T) { tests := []struct { name string