Iterative Review with Defect Correction

The following is a simple work-flow example of a peer iterative code review when a defect is found.

Note:

The iterative review process can be used only for post-commit reviews.

Bug fixing

1. Author Creates a Review

To create a review, click Create Review on the Code Review Board window. Add review data (Review title, Moderator, Author, Reviewer, Revisions, and Description) and click Create to complete creating the review.

Create review

2. Reviewer Studies the Code

During the code review process the reviewer may detect a defect. In this case the reviewer can add a comment to the defect.

Discussions in code

3. Reviewer Rejects the Author’s Work

The reviewer clicks Complete Review, and if the review has a defect it gets the Rework Needed status.

complete review

4. Author Fixes the Defect

The author will see the Rework Needed next to the review in the list. The author needs to fix the defect that had been indicated by the reviewer. After having fixed all the defects the author must commit all the updates to a repository and then add the new revision range to the review. After having fixed the defect and adding the new revision range to the review, the author marks the comment as Fixed.

Fixed

5. Reviewer Examined the Corrected Defect and Accepts the Code

Now the reviewer can see that the defect is fixed. The reviewer studies the corrected code and closes the comment by clicking Close. After that, the reviewer clicks Complete Review. The reviewer can also complete the review process without closing opened comments.

If the review has further comments on the code, they clicks Reopen in the comment. After that, the reviewer clicks Complete Review.

6. Author Closes the Review

Once the reviewer has completed the review, the author can close it by clicking Close Review.

If a moderator participates in the review, and the author and moderator are not the same person, then only moderator can close the review.

If the author or moderator needs to resume working on the closed review, they can click Reopen and renew the review process.

Closing the review means the end of the code review process.

Author closes a review