Skip to content
This repository has been archived by the owner on Jan 3, 2025. It is now read-only.

Commit

Permalink
Fix unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
hainguyen committed May 27, 2017
1 parent fbed675 commit b754f5a
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ public class FormatHtmlTest {
@Test
public void testFormatHtml() {
String mixTextAndHtml = StringUtils.formatRichText("Hello world https://community.mycollab.com <b>Hai Nguyen</b>");
Assert.assertEquals("Hello world <a href=\"https://community.mycollab.com\" target=\"_blank\">https://community.mycollab.com</a> <b>Hai Nguyen</b>", mixTextAndHtml);
Assert.assertEquals("Hello world \n" +
"<a href=\"https://community.mycollab.com\" target=\"_blank\">https://community.mycollab.com</a> \n" +
"<b>Hai Nguyen</b>", mixTextAndHtml);

String pureHtml = StringUtils.formatRichText("https://mycollab.com");
Assert.assertEquals("<a href=\"https://mycollab.com\" target=\"_blank\">https://mycollab.com</a>", pureHtml);
Expand Down

0 comments on commit b754f5a

Please sign in to comment.