This repository has been archived by the owner on Jun 27, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 611
support compile time checks for regen #698
Labels
Comments
Proposed patch below:
|
@bogdanlytvynovskyi have you considered opening a PR for this? This is something I am also interested in! :) |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Requested feature A clear description of the desired feature and an example of
how it would be used.
For each generated interface mock include a line like:
var _ Interface = (*MockInterface)(nil)
in mock fileWhy the feature is needed A clear description of how this feature is not
served by existing functionality in gomock.
Often build step and generation step are separated. The workflow for developer should look like:
However when working with old interfaces, and updating those - more often than not people tend to forget to do the generation step. If there is no mock usage within this repository everything is going to be fine in terms of build/test for this repository, but consumers of this package in a different repository are going to break. Which requires going back and releasing new "fixed" version. The proposal is to enforce build failure in case generated files are not updated appropriately.
WDYT?
The text was updated successfully, but these errors were encountered: