Skip to content

Commit 22b89bb

Browse files
CalumR23brianchandotcom
authored andcommitted
LRCI-6531 Rework when and to who we send Playwright failures in slack
1 parent 80b988a commit 22b89bb

File tree

1 file changed

+18
-2
lines changed

1 file changed

+18
-2
lines changed

modules/test/jenkins-results-parser/src/main/java/com/liferay/jenkins/results/parser/test/clazz/group/PlaywrightBatchTestClassGroup.java

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -865,12 +865,28 @@ private void _loadPlaywrightJSONObjects() {
865865
}
866866

867867
private void _sendNotification(String message) {
868+
String topLevelBuildURL = System.getenv("TOP_LEVEL_BUILD_URL");
869+
870+
if (!topLevelBuildURL.contains("(release)") ||
871+
!topLevelBuildURL.contains(
872+
"test-portal-acceptance-upstream-dxp(master)") ||
873+
!topLevelBuildURL.contains(
874+
"test-portal-testsuite-upstream(master)")) {
875+
876+
return;
877+
}
878+
868879
StringBuilder sb = new StringBuilder();
869880

870881
sb.append(message);
871-
sb.append(" <@U04GTH03Q>, <@U01EV0V1Y6N>\n");
872882

873-
sb.append(System.getenv("TOP_LEVEL_BUILD_URL"));
883+
if (topLevelBuildURL.contains("(release)")) {
884+
sb.append(" <@U04HF3T8M>");
885+
}
886+
887+
sb.append(" <@U01EV0V1Y6N>\n");
888+
889+
sb.append(topLevelBuildURL);
874890

875891
NotificationUtil.sendSlackNotification(
876892
sb.toString(), "#ci-notifications", ":playwright:",

0 commit comments

Comments
 (0)