Did
Copied the following struct:
type foobar interface {
baz(context.Context, int)
}
and ran mokku, and pasted the result.
Expected
A mock struct that compiles.
Got
A compile error, because the resulting mocked method attempts to pass context as a parameter to the underlying Func.
Suggestion
In the case that parameters are not named, we should create a dummy variable name.
a,b, etc is probably fine for unnamed parameters. If users have more than 26 variable names then, well... there are bigger design issues at hand.
Did
Copied the following struct:
and ran
mokku, and pasted the result.Expected
A mock struct that compiles.
Got
A compile error, because the resulting mocked method attempts to pass
contextas a parameter to the underlyingFunc.Suggestion
In the case that parameters are not named, we should create a dummy variable name.
a,b, etc is probably fine for unnamed parameters. If users have more than 26 variable names then, well... there are bigger design issues at hand.