Install and use ginkgo cli at project level #892
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Currently, in the project the ginkgo cli tool is used by
some Makefile targets of the project and at Go level.
However, the project assumes that the cli tool is installed in the
user's environment. This leads to errors when trying to use
the Makefile targets and the user being confused as to why.
Aside from that, even if the user has the tool in the environment, the
version used by t might be different than the version that is specified
in go.mod, which might lead to errors when running the tool and
different observed behavior between users.
This set of changes ensures that the tools used by the Makefile are the
ones installed by it. This ensures that anyone that uses the project
and runs the ginkgo cli tool using the Makefile targets will use the same
version of the tool.
The tool is now always installed in the
bin
directoryof the project's path.
Users of the project that want to directly use the installed tool
manually should run it using the binary installed at project
level to ensure that there are no differences in the tool version.
Finally, remove the explicit install of the
ginkgo
binary in the CIworkflow as it is now automatically installed when running the tests
through the Makefile.