From c21ea14af185d725d819e8dfb1cb52ff39c72e46 Mon Sep 17 00:00:00 2001 From: Joe Steele Date: Fri, 1 Mar 2013 12:30:25 -0500 Subject: [PATCH] Fix unit tests. --- .../com/fsck/k9/helper/HtmlConverterTest.java | 6 +++--- .../com/fsck/k9/mail/internet/ViewablesTest.java | 16 ++++------------ 2 files changed, 7 insertions(+), 15 deletions(-) diff --git a/tests/src/com/fsck/k9/helper/HtmlConverterTest.java b/tests/src/com/fsck/k9/helper/HtmlConverterTest.java index a930fc94b..36deacd06 100644 --- a/tests/src/com/fsck/k9/helper/HtmlConverterTest.java +++ b/tests/src/com/fsck/k9/helper/HtmlConverterTest.java @@ -23,7 +23,7 @@ public class HtmlConverterTest extends TestCase { "\n" + "Nice job :)\n" + ">> Guess!"; - String result = HtmlConverter.textToHtml(message, false); + String result = HtmlConverter.textToHtml(message); writeToFile(result); assertEquals("
Panama!

Bob Barker <bob@aol.com> wrote:
a canal

Dorothy Jo Gideon <dorothy@aol.com> espoused:
A man, a plan...
Too easy!

Nice job :)
Guess!
", result); } @@ -37,7 +37,7 @@ public class HtmlConverterTest extends TestCase { "> LOL F1RST!!!!!\n" + ">\n" + "> :)"; - String result = HtmlConverter.textToHtml(message, false); + String result = HtmlConverter.textToHtml(message); writeToFile(result); assertEquals("
*facepalm*

Bob Barker <bob@aol.com> wrote:
A wise man once said...

LOL F1RST!!!!!

:)
", result); } @@ -60,7 +60,7 @@ public class HtmlConverterTest extends TestCase { ">>>> four\n" + ">>>>> five\n" + ">>>>>> six"; - String result = HtmlConverter.textToHtml(message, false); + String result = HtmlConverter.textToHtml(message); writeToFile(result); assertEquals("
zero
one
two
three
four
five
six
", result); } diff --git a/tests/src/com/fsck/k9/mail/internet/ViewablesTest.java b/tests/src/com/fsck/k9/mail/internet/ViewablesTest.java index 4aae4531f..e0ed3125f 100644 --- a/tests/src/com/fsck/k9/mail/internet/ViewablesTest.java +++ b/tests/src/com/fsck/k9/mail/internet/ViewablesTest.java @@ -29,12 +29,10 @@ public class ViewablesTest extends AndroidTestCase { String expectedText = bodyText; String expectedHtml = - "" + "
" +
                 "K-9 Mail rocks :>" +
-                "
" + - ""; + ""; assertEquals(expectedText, container.text); assertEquals(expectedHtml, container.html); @@ -56,9 +54,7 @@ public class ViewablesTest extends AndroidTestCase { String expectedText = "K-9 Mail rocks :>"; String expectedHtml = - "" + - bodyText + - ""; + bodyText; assertEquals(expectedText, container.text); assertEquals(expectedHtml, container.html); @@ -91,7 +87,6 @@ public class ViewablesTest extends AndroidTestCase { "------------------------------------------------------------------------\n\n" + bodyText2; String expectedHtml = - "" + "
" +
                 bodyText1 +
@@ -101,8 +96,7 @@ public class ViewablesTest extends AndroidTestCase {
                 "
" +
                 bodyText2 +
-                "
" + - ""; + "
"; assertEquals(expectedText, container.text); @@ -158,7 +152,6 @@ public class ViewablesTest extends AndroidTestCase { "\n" + innerBodyText; String expectedHtml = - "" + "
" +
                 bodyText +
@@ -183,8 +176,7 @@ public class ViewablesTest extends AndroidTestCase {
                 "
" +
                 innerBodyText +
-                "
" + - ""; + "
"; assertEquals(expectedText, container.text); assertEquals(expectedHtml, container.html);