stable

Clone or download

Read-only

request #34034 Interpret commonmark in pull-request comments notifications

How to test: - Add a global comment and an inline comment on a pull-request using the commonmark syntax. - Open your mailhog local instance - For each mail notification: --> The [HTML] tab shows it interpreted --> The [Plain text] tab shows it not interpreted Change-Id: Ic6f36c75a06a71a6cca100b8da7b7bef8a46cb2c

Modified Files

Name
M plugins/pullrequest/include/PullRequest/Comment/Comment.php +2 −4 Go to diff View file
M plugins/pullrequest/include/PullRequest/Comment/Notification/PullRequestNewCommentContentPresenter.php +6 −37 Go to diff View file
M plugins/pullrequest/include/PullRequest/Comment/Notification/PullRequestNewCommentNotification.php +6 −3 Go to diff View file
M plugins/pullrequest/include/PullRequest/Comment/Notification/PullRequestNewCommentNotificationToProcessBuilder.php +11 −44 Go to diff View file
M plugins/pullrequest/include/PullRequest/InlineComment/InlineComment.php +2 −1 Go to diff View file
M plugins/pullrequest/include/PullRequest/InlineComment/InlineCommentCreator.php +2 −2 Go to diff View file
M plugins/pullrequest/include/PullRequest/InlineComment/Notification/PullRequestNewInlineCommentContentPresenter.php +8 −49 Go to diff View file
M plugins/pullrequest/include/PullRequest/InlineComment/Notification/PullRequestNewInlineCommentNotification.php +4 −2 Go to diff View file
M plugins/pullrequest/include/PullRequest/InlineComment/Notification/PullRequestNewInlineCommentNotificationToProcessBuilder.php +12 −50 Go to diff View file
A plugins/pullrequest/include/PullRequest/Notification/FormatNotificationContent.php +29 −0 Go to diff View file
A plugins/pullrequest/include/PullRequest/Notification/NotificationContentFormatter.php +60 −0 Go to diff View file
M plugins/pullrequest/include/PullRequest/Notification/PullRequestNotificationSupport.php +19 −2 Go to diff View file
M plugins/pullrequest/include/PullRequest/PullRequestCreator.php +2 −2 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/CommentRepresentation.php +2 −1 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/Info/PullRequestInfoUpdater.php +2 −2 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/PullRequestInlineCommentRepresentation.php +2 −2 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/PullRequestRepresentation.php +2 −2 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/PullRequestsResource.php +4 −3 Go to diff View file
M plugins/pullrequest/include/PullRequest/REST/v1/TimelineInlineCommentRepresentation.php +2 −2 Go to diff View file
A plugins/pullrequest/include/PullRequest/Timeline/TimelineComment.php +33 −0 Go to diff View file
M plugins/pullrequest/templates/comment/pull-request-new-comment-mail-content.mustache +1 −1 Go to diff View file
M plugins/pullrequest/templates/comment/pull-request-new-inline-comment-mail-content.mustache +1 −1 Go to diff View file
M plugins/pullrequest/tests/integration/PullRequestUpdaterTest.php +8 −8 Go to diff View file
A plugins/pullrequest/tests/unit/Builders/CommentTestBuilder.php +72 −0 Go to diff View file
A plugins/pullrequest/tests/unit/Builders/InlineCommentTestBuilder.php +86 −0 Go to diff View file
M plugins/pullrequest/tests/unit/Builders/PullRequestTestBuilder.php +14 −2 Go to diff View file
M plugins/pullrequest/tests/unit/Comment/Notification/PullRequestNewCommentNotificationTest.php +73 −24 Go to diff View file
M plugins/pullrequest/tests/unit/Comment/Notification/PullRequestNewCommentNotificationToProcessBuilderTest.php +5 −2 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/InlineCommentCreatorTest.php +3 −3 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/InlineCommentRetrieverTest.php +2 −2 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/InlineCommentUpdaterTest.php +8 −8 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/Notification/InlineCommentCodeContextExtractorTest.php +3 −3 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/Notification/PullRequestNewInlineCommentNotificationTest.php +79 −42 Go to diff View file
M plugins/pullrequest/tests/unit/InlineComment/Notification/PullRequestNewInlineCommentNotificationToProcessBuilderTest.php +5 −3 Go to diff View file
A plugins/pullrequest/tests/unit/Notification/NotificationContentFormatterTest.php +95 −0 Go to diff View file
M plugins/pullrequest/tests/unit/PullRequestCloserTest.php +2 −2 Go to diff View file
M plugins/pullrequest/tests/unit/PullRequestReopenerTest.php +4 −4 Go to diff View file
M plugins/pullrequest/tests/unit/REST/v1/Comment/ParentIdValidatorForCommentTest.php +4 −3 Go to diff View file
M plugins/pullrequest/tests/unit/REST/v1/Comment/ParentIdValidatorForInlineCommentTest.php +3 −3 Go to diff View file
M plugins/pullrequest/tests/unit/REST/v1/CommentRepresentationTest.php +3 −2 Go to diff View file
M plugins/pullrequest/tests/unit/REST/v1/Info/PullRequestInfoUpdaterTest.php +7 −7 Go to diff View file
M plugins/pullrequest/tests/unit/REST/v1/PullRequestInlineCommentRepresentationTest.php +3 −3 Go to diff View file
M plugins/pullrequest/tests/unit/REST/v1/StatusPatcherTest.php +2 −2 Go to diff View file
M plugins/pullrequest/tests/unit/REST/v1/TimelineInlineCommentRepresentationTest.php +3 −3 Go to diff View file
M plugins/pullrequest/tests/unit/Reference/ReferenceFactoryTest.php +2 −2 Go to diff View file
A plugins/pullrequest/tests/unit/Stub/FormatNotificationContentStub.php +49 −0 Go to diff View file