Refactor and add tests coverage on package runconfig#14134
Merged
LK4D4 merged 1 commit intomoby:masterfrom Jul 1, 2015
Merged
Conversation
d3b690f to
c85927d
Compare
Member
Author
There was a problem hiding this comment.
It felt weird that always:2 was failing (expected) but not always:2:1.
Contributor
|
LGTM |
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
c85927d to
d4aec5f
Compare
Member
Author
Contributor
|
@vdemeester Pls create issues about weird things that you've found. |
LK4D4
added a commit
that referenced
this pull request
Jul 1, 2015
Refactor and add tests coverage on package runconfig
Member
Author
|
Will do 😉 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
After opts, this is another big one — probably a little too big.. It's the time for
runconfigto get covered 🐸.What this PR does is :
parse_test.go, the merging one intomerge_test.go, and so on).compare_test.gofor more extensive testing of theCompareconfig method.config_test.goto testEntrypointandCommandstructs (that might be overkill but… oh well 😺).exec_test.goto testParseExec(which is inexec.go).hostconfig_test.goforhostconfig.gotests, with fixtures (similar to what was done withconfig_test.go).parse_test.goto cover more cases. As some of some parse thingy are calling theoptspackage and some aren't I tried to limit test case for those shared validation cases. I'll use the data gathered by those PR to update the issue I created about the need to centralize some of the checks (Proposal : centralize validations / checks between cli, api & builder #13824).There is a few
FIXMEin there, question I was asking myself and not really able to answer. I'll comment on them directly in this PR.It's probably gonna be a little tricky to merge, because some PRs might changes these files a bit (like #14133) — but I'll rebase, fix or remove tests if needed (or even split this PR into severals).
Thanks for the reviews :)
Signed-off-by: Vincent Demeester vincent@sbr.pm