Fix issue: https://pagure.io/koji/issue/758 Add unit test for koji_cli.commands.handle_dist_repo.
:thumbsup:
:thumbsup: (I don't think, pagure will catch 'Fix issue: ...' line, have you ever tried this syntax?) https://pagure.io/pagure/blob/72db85195a3b7dc36512665806b422d1c12efcfb/f/pagure/lib/link.py#_19
(I don't think, pagure will catch 'Fix issue: ...' line, have you ever tried this syntax?)
Does pagure even look in the PR initial comment for such lines? The only place I know of is the pagure git hook which can be optionally configured (and is for Koji). From the current code, it looks like this is the only place that calls get_relation(). This code only looks at the git commit messages that are pushed to the master branch.
get_relation()
What does look at the initial comment field is the script I've been using to help manage merges.
https://github.com/mikem23/pagure-tool
When I merge a PR, this script looks for related issues. It's a little more aggressive than Pagure. The issues that it finds are added to the initial commit message that it generates for the merge. Because it references them in that merge commit in the way that Pagure expects, Pagure will then close and/or comment on them when the merge is pushed.
I recently expanded the code to handle this case, so it should handle this case. Granted it also looks at the branch name (issue758 in this case), so it would figure it out from that too.
(suffice to say, the issue ref on this PR is fine :smile: )
Commit 41b74fcc fixes this pull-request
Pull-Request has been merged by mikem
Fix issue: https://pagure.io/koji/issue/758
Add unit test for koji_cli.commands.handle_dist_repo.