feat: support --ignore flag in can-i-merge command#174
Conversation
c1f910f to
70798ec
Compare
70798ec to
79c4429
Compare
| -h, [--branch=BRANCH] | ||
| # Repository branch of the consumer version | ||
| -r, [--auto-detect-version-properties], [--no-auto-detect-version-properties] | ||
| -r, [--auto-detect-version-properties], [--no-auto-detect-version-properties], [--skip-auto-detect-version-properties] |
There was a problem hiding this comment.
What's going on with all of these --skip-.. variants?
There was a problem hiding this comment.
I just ran a command from README to re-generate docs, so I guess someone added these flags but never re-generated the docs
There was a problem hiding this comment.
Looks like it came from this commit, (documenting of the option), which was released in thor 1.3.1. Downgrading thor to 1.3.0 and running ruby script/update-cli-usage-in-readme.rb will generate the readme without the --skip* opts
The option itself has been there since 2009 - commit
effectively --no-foo is the same as --skip-foo
There was a problem hiding this comment.
You can rebase against master now as I've performed that readme update in a separate PR
| ENV.fetch("PACT_BROKER_CAN_I_DEPLOY_IGNORE", "").split(",").collect(&:strip).collect{ |i| { pacticipant: i } } | ||
| end | ||
| def ignore_merge_selectors_from_environment_variable | ||
| ENV.fetch("PACT_BROKER_CAN_I_MERGE_IGNORE", "").split(",").collect(&:strip).collect{ |i| { pacticipant: i } } |
There was a problem hiding this comment.
Right, yes can't specify versions here :)
There was a problem hiding this comment.
I just copied the behavior of can-i-deploy ignore flag/var :)
|
Looks good to me, I've updated the proposed test and added a new one to test the ignore logic, whereby a broker result contains 2 indiv verification results for 2 consumers, 1 failing, 1 passing. see #177 (including a rebase against master to avoid the additional readme update noise) In one case, the broker returns an ignored verification, the matrix lists it, and exits successfully. In the other case, the broker returns an undeployable verification, and computer says now |
|
Thanks @YOU54F ! With your PR in flight, should we close this one? |
|
merged as part of #177, ty |
This should bring it up-to-date with can-i-deploy.
Tested by unit test and also by building it and running locally against dockerized broker.