Prevent users from publishing empty (no modifications made) review request drafts.
Review Request #6322 — Created Sept. 14, 2014 and submitted — Latest diff uploaded
When a user submits an empty draft for a review request a warning is issued to let them know they did not make any modifications.
The general flow is:
1. In the review_request_draft model determine if there were any changes to any of the fields, if not then raise a 'Not Modified' exception
2. The review_request_draft controller/resource will catch the 'Not Modified' exception and return an appropriate error message to the Client JS to display a meaningful message to the user.
3. Client JS displays error message and the 'Publish Changes' and 'Discard Draft' buttons remain disabled.
4. Once the user updates (edits and confirms by clicking 'OK') a field (Description, Testing Done) then the 'Publish Changes' and 'Discard Draft' buttons are re-enabled.
Tried "not-modifying" the Description, and Testing Done fields to determine the output.
Wrote test case to publish an empty draft (test case passes).
Postive Test Cases:
Added a file (successful publish).
Remove a file (successful publish).
Changing the description field (successful publish).
Add comments (successful publish).
Add branch/target people/bug number.