MessageOptions { @Override public String toString() { return new StringJoiner(", ", "MessageOptions [", "]") .add(String.format("subject=%s", subject)) .add(String.format("bodyHtml=%s", bodyHtml)) .add(String.format("bodyText=%s", bodyText)) .add(String.format("bodyHtmlUrlPlaceholder=%s", bodyHtmlUrlPlaceholder)) .add(String.format("bodyTextUrlPlaceholder=%s", bodyTextUrlPlaceholder)) .add(String.format("successHtml=%s", successHtml)) .toString(); } MessageOptions(@JsonProperty("subject") String subject,
                        @JsonProperty("bodyHtmlFile") String bodyHtml,
                        @JsonProperty("bodyTextFile") String bodyText,
                        @JsonProperty("bodyHtmlUrlPlaceholder") String bodyHtmlUrlPlaceholder,
                        @JsonProperty("bodyTextUrlPlaceholder") String bodyTextUrlPlaceholder,
                        @JsonProperty("successHtmlFile") String successHtml); String getSubject(); String getBodyHtml(); String getBodyText(); String getBodyHtmlUrlPlaceholder(); String getBodyTextUrlPlaceholder(); String getSuccessHtml(); @Override boolean equals(Object obj); @Override int hashCode(); @Override String toString();  }
@Test void testToString() { MessageOptions messageOptions = new MessageOptions( "subject", "bodyHtml", "bodyText", "htmlPlaceholder", "textPlaceholder", "successHtml"); String expected = "MessageOptions " + "[subject=subject, bodyHtml=bodyHtml, bodyText=bodyText, " + "bodyHtmlUrlPlaceholder=htmlPlaceholder, bodyTextUrlPlaceholder=textPlaceholder, " + "successHtml=successHtml]"; assertEquals(expected, messageOptions.toString()); }