aboutsummaryrefslogtreecommitdiffstats
path: root/tests/src/cgeo/geocaching/utils/HtmlUtilsTest.java
diff options
context:
space:
mode:
Diffstat (limited to 'tests/src/cgeo/geocaching/utils/HtmlUtilsTest.java')
-rw-r--r--tests/src/cgeo/geocaching/utils/HtmlUtilsTest.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/src/cgeo/geocaching/utils/HtmlUtilsTest.java b/tests/src/cgeo/geocaching/utils/HtmlUtilsTest.java
index 65e86b8..e75c2e6 100644
--- a/tests/src/cgeo/geocaching/utils/HtmlUtilsTest.java
+++ b/tests/src/cgeo/geocaching/utils/HtmlUtilsTest.java
@@ -15,4 +15,9 @@ public class HtmlUtilsTest extends TestCase {
assertThat(HtmlUtils.extractText("<b>bold</b>")).isEqualTo("bold");
}
+ public static void testRemoveExtraParagraph() {
+ assertThat(HtmlUtils.removeExtraParagraph("<p></p>")).isEqualTo("");
+ assertThat(HtmlUtils.removeExtraParagraph("<p>Test</p>")).isEqualTo("Test");
+ assertThat(HtmlUtils.removeExtraParagraph("<p>1</p><p>2</p>")).isEqualTo("<p>1</p><p>2</p>");
+ }
}