Create mock for RemotExecutor interface with mockery
The following discussion from !1680 (merged) should be addressed:
-
@steveazz started a discussion: (+1 comment) If we do it like below it will just create this
mock_RemoteExecutor.gowhich should probably be used instead of the hand-rolled fakeRemoteExecutormockery $(MOCKERY_FLAGS) -dir=./executors/kubernetes -all -inpkgWhat do you think if inside this merge request we set it to the suggestion above, and then in a follow up merge request we remove the fakeRemoteExecutor, what do you think?
Proposal
- Update https://gitlab.com/gitlab-org/gitlab-runner/-/blob/ee80e237c50b733e4ec2afc879ee022d93bbb373/Makefile#L143 to generate mocks for all of
executors/kubernetes - Remove the use of fakeRemoteExecutor and use the generated mock instead.