mozreview: Add a test for submitter==reviewer rewriting (
bug 1299071) r?smacleod
MozReview-Commit-ID: 5G20VeBJ5Sv
--- a/hgext/reviewboard/tests/test-review-commit-rewrite.t
+++ b/hgext/reviewboard/tests/test-review-commit-rewrite.t
@@ -76,10 +76,53 @@ Rewriting on a child should work against
id: 2
reviewers:
- reviewer
summary:
- Bug 1 - Initial commit to review r=reviewer
- ''
- 'MozReview-Commit-ID: 124Bxg'
+Check rewriting when submitter == reviewer
+
+ $ bugzilla create-bug TestProduct TestComponent 'Second Bug'
+ $ echo another >> foo
+ $ hg commit -m 'Bug 2 - Initial commit to review r?l3author' foo
+ $ exportbzauth l3author@example.com password
+ $ hg --verbose --config bugzilla.username=l3author@example.com --config bugzilla.apikey=$l3key push -c .
+ pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+ searching for changes
+ 1 changesets found
+ uncompressed size of bundle content:
+ 256 (changelog)
+ 165 (manifests)
+ 135 foo
+ remote: adding changesets
+ remote: adding manifests
+ remote: adding file changes
+ remote: added 1 changesets with 1 changes to 1 files
+ remote: recorded push in pushlog
+ submitting 1 changesets for review
+
+ changeset: 2:ec1c2da051b2
+ summary: Bug 2 - Initial commit to review r?l3author
+ review: http://$DOCKER_HOSTNAME:$HGPORT1/r/4 (draft)
+
+ review id: bz://2/mynick
+ review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/3 (draft)
+
+ publish these review requests now (Yn)? y
+ (published review request 3)
+ $ rbmanage create-review 4 --body-top "Ship-it!" --public --review-flag='r+'
+ created review 2
+ $ rbmanage dump-rewrite-commit 3
+ commits:
+ - commit: ec1c2da051b299ce4473a30fad8c7affddc68d14
+ id: 4
+ reviewers:
+ - l3author
+ summary:
+ - Bug 2 - Initial commit to review r=l3author
+ - ''
+ - 'MozReview-Commit-ID: 5ijR9k'
+
$ mozreview stop
stopped 9 containers