Skip to content

Detect if mockgen and goimports are in the path#278

Merged
mogren merged 1 commit intoaws:masterfrom
nak3:commandPathmock
Jan 3, 2019
Merged

Detect if mockgen and goimports are in the path#278
mogren merged 1 commit intoaws:masterfrom
nak3:commandPathmock

Conversation

@nak3
Copy link
Copy Markdown
Contributor

@nak3 nak3 commented Dec 23, 2018

Description of changes:

This patch adds validation to detect if mockgen and goimports are
in the executable file path before running commands.

Currently, if either mockgen or goimports does not exists, the
program stops, but mock codes are gone.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

This patch adds validation to detect if `mockgen` and `goimports` are
in the executable file path before running commands.

Currently, if either `mockgen` or `goimports` does not exists, the
program stops, but mock codes are gone.

// TODO detect if mockgen or goimports are in the path
var (
requiredCommands = [2]string{"mockgen", "goimports"}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@mogren mogren merged commit 41ca596 into aws:master Jan 3, 2019
@nak3 nak3 deleted the commandPathmock branch January 3, 2019 02:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants