Pegomock supports Go Generics in its new release. Before generics, we had to generate matchers for custom types, and would generate lots of functions like. To generate a mock, in a terminal we can now run: This will give us a new struct type and a function.

2m read timeFrom medium.com
Post cover image
Table of contents
How Pegomock supports Go Generics in its new releaseGitHub - petergtz/pegomock: Pegomock is a powerful, yet simple mocking framework for the Go…

Sort: