Skip to content

Ignore _mock files during commit? #196

Answered by tatomir146
ghost asked this question in Archive
Discussion options

You must be logged in to vote

You actually have to generate mock files.

### Test Mocks

Go Mockgen is used for some generated mock files. They are not generated every time, but rather checked in, so be careful
when introducing changes to objects that are mocked. You will have to regenerate and probably manually modify them to remove
e.g. the reference to the module.
​To explicitly generate the mocked files, run `make mocks` in the root folder.

@didiladi adding this as a build step would be possible, but what in case there is a error during go generate?

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@patrickpichler
Comment options

@tatomir146
Comment options

@patrickpichler
Comment options

@patrickpichler
Comment options

Answer selected by tatomir146
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Archive
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #173 on February 17, 2021 15:02.