BranchNotificationMessageBuilderSlack { public Message getTranslatedMessage(String channel, String threadTs) { Message message = new Message(); message.setChannel(channel); message.setThreadTs(threadTs); message.setText("Translations are ready !! :party:"); return message; }  Message getNewMessage(String channel, String pr, List<String> sourceStrings); Message getUpdatedMessage(String channel, String threadTs, String pr, List<String> sourceStrings); Message getTranslatedMessage(String channel, String threadTs); Message getScreenshotMissingMessage(String channel, String threadTs);  }
@Test public void testGetTranslatedMessage() { Message newMessage = branchNotificationMessageBuilderSlack.getTranslatedMessage("channel-test", "pr-test"); String json = objectMapper.writeValueAsStringUnchecked(newMessage); assertEquals("{\"channel\":\"channel-test\",\"text\":\"Translations are ready !! :party:\",\"attachments\":[],\"thread_ts\":\"pr-test\"}", json); }