RFR: 1588: Bridge messages should not be sent for PRs in draft state

Zhao Song zsong at openjdk.org
Thu Feb 9 19:39:16 UTC 2023

On Thu, 9 Feb 2023 17:48:28 GMT, Guoxiong Li <gli at openjdk.org> wrote:

> Hi all,
> This patch prevents the `mailling bridge bot` from sending emails when a PR is draft.
> And the related test case is added.
> Thanks for taking the time to review.
> Best Regards,
> -- Guoxiong

bots/mlbridge/src/test/java/org/openjdk/skara/bots/mlbridge/MailingListBridgeBotTests.java line 3553:

> 3551:             assertEquals(3, archiveContainsCount(archiveFolder.path(), "RFR: 1234: This is a pull request"));
> 3552:             assertEquals(1, archiveContainsCount(archiveFolder.path(), "This is a comment"));
> 3553:             assertEquals(1, archiveContainsCount(archiveFolder.path(), "This is a new comment"));

@kevinrushforth Hi Kevin, see Li's test case here. This pr was 'rfr' and he converted it to draft. When the pr was in draft mode, he added a comment 'This is a new comment' and run the bot. As expected, there is no email sent. After that, he converted the pr to 'rfr' again and run the bot. This time, he got the notification about the comment 'This is a new comment'. So we won't lose the notification permanently. It's just delayed.


PR: https://git.openjdk.org/skara/pull/1469

More information about the skara-dev mailing list