summaryrefslogtreecommitdiff
path: root/svtools/qa/unit/testHtmlReader.cxx
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2019-03-06 21:36:12 +0100
committerMiklos Vajna <vmiklos@collabora.com>2019-03-07 09:39:13 +0100
commit6d5fe4dca30452b8c64834aaf175d10497b75f71 (patch)
treed77b0bfa0a180150b1cc559bf0dd88c6c375a37f /svtools/qa/unit/testHtmlReader.cxx
parent723ad50fff71858d96ff31b0a9ceeba556ff675c (diff)
CppunitTest_svtools_html: use CPPUNIT_TEST_FIXTURE()
Change-Id: Icf4d3a649c5e6a53035c2a1573a8dd7154db2edd Reviewed-on: https://gerrit.libreoffice.org/68831 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'svtools/qa/unit/testHtmlReader.cxx')
-rw-r--r--svtools/qa/unit/testHtmlReader.cxx15
1 files changed, 3 insertions, 12 deletions
diff --git a/svtools/qa/unit/testHtmlReader.cxx b/svtools/qa/unit/testHtmlReader.cxx
index 6df6b5541c2d..abda6f2725fc 100644
--- a/svtools/qa/unit/testHtmlReader.cxx
+++ b/svtools/qa/unit/testHtmlReader.cxx
@@ -10,6 +10,7 @@
#include <cppunit/TestFixture.h>
#include <cppunit/extensions/HelperMacros.h>
+#include <unotest/bootstrapfixturebase.hxx>
#include <svtools/parhtml.hxx>
#include <tools/ref.hxx>
#include <tools/stream.hxx>
@@ -45,17 +46,9 @@ void TestHTMLParser::NextToken(HtmlTokenId nToken)
/// Tests HTMLParser.
class Test : public CppUnit::TestFixture
{
-public:
- void testTdf114428();
- void testLineBreak();
-
- CPPUNIT_TEST_SUITE(Test);
- CPPUNIT_TEST(testTdf114428);
- CPPUNIT_TEST(testLineBreak);
- CPPUNIT_TEST_SUITE_END();
};
-void Test::testTdf114428()
+CPPUNIT_TEST_FIXTURE(Test, testTdf114428)
{
SvMemoryStream aStream;
OString aDocument("<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<html>hello</html>");
@@ -70,7 +63,7 @@ void Test::testTdf114428()
CPPUNIT_ASSERT_EQUAL(OUString("hello"), xParser->m_aDocument.trim());
}
-void Test::testLineBreak()
+CPPUNIT_TEST_FIXTURE(Test, testLineBreak)
{
SvMemoryStream aStream;
OString aDocument("aaa<br></br>bbb");
@@ -84,8 +77,6 @@ void Test::testLineBreak()
// This was 2, <br></br> was interpreted as 2 line breaks in XHTML mode.
CPPUNIT_ASSERT_EQUAL(1, xParser->m_nLineBreakCount);
}
-
-CPPUNIT_TEST_SUITE_REGISTRATION(Test);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */