gomockctx

Go package with gomock helpers for matching context.Context.

Go Reference Actions Status Coverage GitHub issues GitHub pull requests License Status

## Import ```go import "github.com/romdo/gomockctx" ``` ## Usage ```go // Create a context with a gomockctx ID value. ctx := gomockctx.New(context.Background()) // Match against a context with a gomockctx ID. someMock.EXPECT(). Get(gomockctx.Is(ctx), "foo"). Return("bar", nil) // Use context with gomockctx ID when calling function. someMock.Get(ctx, "foo") ``` ## Documentation Please see the [Go Reference](https://pkg.go.dev/github.com/romdo/gomockctx#section-documentation). ## License [MIT](https://github.com/romdo/gomockctx/blob/main/LICENSE)