stable

Clone or download

Read-only

User must be able to set a parent id in pull request comments

part of story #29240 reply to pull request comment How to test: in REST route /pull_requests/id/comments you should be able to add a new paramter parent_id in payload, new parent id is stored in db same for REST route /pull_requests/id/inline-comments Change-Id: Ie82c3b6f7d10366bc161846d38b0f4137b9cfdde

Modified Files

Name
M plugins/pullrequest/db/install.sql +13 −9 Go to diff View file
A plugins/pullrequest/db/mysql/updates/2022/202210281100_add_pullrequest_parent_in_comment_table.php +71 −0 Go to diff View file
M plugins/pullrequest/include/PullRequest/Comment/Comment.php +14 −27 Go to diff View file
M plugins/pullrequest/include/PullRequest/Comment/Dao.php +6 −6 Go to diff View file
M plugins/pullrequest/include/PullRequest/Comment/Factory.php +8 −22 Go to diff View file
M plugins/pullrequest/include/PullRequest/Factory.php +1 −0 Go to diff View file
M plugins/pullrequest/include/PullRequest/InlineComment/Dao.php +10 −9 Go to diff View file
M plugins/pullrequest/include/PullRequest/InlineComment/InlineComment.php +27 −37 Go to diff View file
M plugins/pullrequest/include/PullRequest/InlineComment/InlineCommentCreator.php +3 −2 Go to diff View file
A plugins/pullrequest/include/PullRequest/REST/v1/Comment/ParentIdValidatorForComment.php +53 −0 Go to diff View file
A plugins/pullrequest/include/PullRequest/REST/v1/Comment/ParentIdValidatorForInlineComment.php +53 −0 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/CommentPOSTRepresentation.php +7 −2 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/PullRequestInlineCommentPOSTRepresentation.php +4 −0 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/PullRequestRepresentation.php +6 −0 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/PullRequestsResource.php +12 −4 Go to diff View file
M plugins/pullrequest/include/PullRequest/Timeline/Factory.php +3 −2 Go to diff View file
M plugins/pullrequest/tests/unit/Comment/Notification/PullRequestNewCommentNotificationToProcessBuilderTest.php +2 −1 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/InlineCommentCreatorTest.php +5 −1 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/InlineCommentRetrieverTest.php +1 −0 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/InlineCommentUpdaterTest.php +7 −7 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/Notification/InlineCommentCodeContextExtractorTest.php +2 −1 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/Notification/PullRequestNewInlineCommentNotificationTest.php +2 −1 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/Notification/PullRequestNewInlineCommentNotificationToProcessBuilderTest.php +2 −1 Go to diff View file
A plugins/pullrequest/tests/unit/REST/v1/Comment/ParentIdValidatorForCommentTest.php +104 −0 Go to diff View file
A plugins/pullrequest/tests/unit/REST/v1/Comment/ParentIdValidatorForInlineCommentTest.php +109 −0 Go to diff View file