[Libreoffice-commits] .: sw/qa

Miklos Vajna vmiklos at kemper.freedesktop.org
Fri Apr 27 06:37:46 PDT 2012


 sw/qa/extras/ooxmltok/ooxmltok.cxx   |   22 +++++------
 sw/qa/extras/rtfexport/rtfexport.cxx |   18 ++++-----
 sw/qa/extras/rtftok/rtftok.cxx       |   68 +++++++++++++++++------------------
 3 files changed, 54 insertions(+), 54 deletions(-)

New commits:
commit 1fc8ccaf585285d7b2b4e5ba7f588be606691b74
Author: Miklos Vajna <vmiklos at suse.cz>
Date:   Fri Apr 27 15:36:23 2012 +0200

    sw/qa/extras: no need to use different class names for these tests

diff --git a/sw/qa/extras/ooxmltok/ooxmltok.cxx b/sw/qa/extras/ooxmltok/ooxmltok.cxx
index e5bdece..65fb287 100644
--- a/sw/qa/extras/ooxmltok/ooxmltok.cxx
+++ b/sw/qa/extras/ooxmltok/ooxmltok.cxx
@@ -47,7 +47,7 @@ using rtl::OUString;
 using rtl::OUStringBuffer;
 using namespace com::sun::star;
 
-class OoxmlModelTest : public test::BootstrapFixture, public unotest::MacrosTest
+class Test : public test::BootstrapFixture, public unotest::MacrosTest
 {
 public:
     virtual void setUp();
@@ -58,7 +58,7 @@ public:
     void testN750935();
     void testN757890();
 
-    CPPUNIT_TEST_SUITE(OoxmlModelTest);
+    CPPUNIT_TEST_SUITE(Test);
 #if !defined(MACOSX) && !defined(WNT)
     CPPUNIT_TEST(testN751054);
     CPPUNIT_TEST(testN751117);
@@ -74,12 +74,12 @@ private:
     uno::Reference<lang::XComponent> mxComponent;
 };
 
-void OoxmlModelTest::load(const OUString& rFilename)
+void Test::load(const OUString& rFilename)
 {
     mxComponent = loadFromDesktop(getURLFromSrc("/sw/qa/extras/ooxmltok/data/") + rFilename);
 }
 
-void OoxmlModelTest::setUp()
+void Test::setUp()
 {
     test::BootstrapFixture::setUp();
 
@@ -87,7 +87,7 @@ void OoxmlModelTest::setUp()
     CPPUNIT_ASSERT(mxDesktop.is());
 }
 
-void OoxmlModelTest::tearDown()
+void Test::tearDown()
 {
     if (mxComponent.is())
         mxComponent->dispose();
@@ -95,7 +95,7 @@ void OoxmlModelTest::tearDown()
     test::BootstrapFixture::tearDown();
 }
 
-void OoxmlModelTest::testN751054()
+void Test::testN751054()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("n751054.docx")));
 
@@ -107,7 +107,7 @@ void OoxmlModelTest::testN751054()
     CPPUNIT_ASSERT(eValue != text::TextContentAnchorType_AS_CHARACTER);
 }
 
-void OoxmlModelTest::testN751117()
+void Test::testN751117()
 {
     load("n751117.docx");
 
@@ -133,7 +133,7 @@ void OoxmlModelTest::testN751117()
     CPPUNIT_ASSERT(xServiceInfo->supportsService("com.sun.star.drawing.LineShape"));
 }
 
-void OoxmlModelTest::testN751017()
+void Test::testN751017()
 {
     load("n751017.docx");
     uno::Reference<text::XTextFieldsSupplier> xTextFieldsSupplier(mxComponent, uno::UNO_QUERY);
@@ -180,7 +180,7 @@ void OoxmlModelTest::testN751017()
     CPPUNIT_ASSERT(bFoundGet);
 }
 
-void OoxmlModelTest::testN750935()
+void Test::testN750935()
 {
     load("n750935.docx");
     uno::Reference<frame::XModel> xModel(mxComponent, uno::UNO_QUERY);
@@ -190,7 +190,7 @@ void OoxmlModelTest::testN750935()
     CPPUNIT_ASSERT_EQUAL(sal_Int16(5), xCursor->getPage());
 }
 
-void OoxmlModelTest::testN757890()
+void Test::testN757890()
 {
     load("n757890.docx");
 
@@ -212,7 +212,7 @@ void OoxmlModelTest::testN757890()
     CPPUNIT_ASSERT_EQUAL(text::HoriOrientation::CENTER, nValue);
 }
 
-CPPUNIT_TEST_SUITE_REGISTRATION(OoxmlModelTest);
+CPPUNIT_TEST_SUITE_REGISTRATION(Test);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
 
diff --git a/sw/qa/extras/rtfexport/rtfexport.cxx b/sw/qa/extras/rtfexport/rtfexport.cxx
index 5bab469..d33ec36 100644
--- a/sw/qa/extras/rtfexport/rtfexport.cxx
+++ b/sw/qa/extras/rtfexport/rtfexport.cxx
@@ -39,7 +39,7 @@ using rtl::OUString;
 using rtl::OUStringBuffer;
 using namespace com::sun::star;
 
-class RtfExportTest : public test::BootstrapFixture, public unotest::MacrosTest
+class Test : public test::BootstrapFixture, public unotest::MacrosTest
 {
 public:
     virtual void setUp();
@@ -47,7 +47,7 @@ public:
     void testZoom();
     void testFdo38176();
 
-    CPPUNIT_TEST_SUITE(RtfExportTest);
+    CPPUNIT_TEST_SUITE(Test);
 #if !defined(MACOSX) && !defined(WNT)
     CPPUNIT_TEST(testZoom);
     CPPUNIT_TEST(testFdo38176);
@@ -61,7 +61,7 @@ private:
     uno::Reference<lang::XComponent> mxComponent;
 };
 
-void RtfExportTest::roundtrip(const OUString& rFilename)
+void Test::roundtrip(const OUString& rFilename)
 {
     uno::Reference<lang::XComponent> xImported = loadFromDesktop(getURLFromSrc("/sw/qa/extras/rtfexport/data/") + rFilename);
     uno::Reference<frame::XStorable> xStorable(xImported, uno::UNO_QUERY);
@@ -74,7 +74,7 @@ void RtfExportTest::roundtrip(const OUString& rFilename)
     mxComponent = loadFromDesktop(aTempFile.GetURL());
 }
 
-int RtfExportTest::getLength()
+int Test::getLength()
 {
     uno::Reference<text::XTextDocument> xTextDocument(mxComponent, uno::UNO_QUERY);
     uno::Reference<container::XEnumerationAccess> xParaEnumAccess(xTextDocument->getText(), uno::UNO_QUERY);
@@ -93,7 +93,7 @@ int RtfExportTest::getLength()
     return aBuf.getLength();
 }
 
-void RtfExportTest::setUp()
+void Test::setUp()
 {
     test::BootstrapFixture::setUp();
 
@@ -101,7 +101,7 @@ void RtfExportTest::setUp()
     CPPUNIT_ASSERT(mxDesktop.is());
 }
 
-void RtfExportTest::tearDown()
+void Test::tearDown()
 {
     if (mxComponent.is())
         mxComponent->dispose();
@@ -109,7 +109,7 @@ void RtfExportTest::tearDown()
     test::BootstrapFixture::tearDown();
 }
 
-void RtfExportTest::testZoom()
+void Test::testZoom()
 {
     roundtrip("zoom.rtf");
 
@@ -121,13 +121,13 @@ void RtfExportTest::testZoom()
     CPPUNIT_ASSERT_EQUAL(sal_Int16(42), nValue);
 }
 
-void RtfExportTest::testFdo38176()
+void Test::testFdo38176()
 {
     roundtrip("fdo38176.rtf");
     CPPUNIT_ASSERT_EQUAL(9, getLength());
 }
 
-CPPUNIT_TEST_SUITE_REGISTRATION(RtfExportTest);
+CPPUNIT_TEST_SUITE_REGISTRATION(Test);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
 
diff --git a/sw/qa/extras/rtftok/rtftok.cxx b/sw/qa/extras/rtftok/rtftok.cxx
index af32761..055f7ce 100644
--- a/sw/qa/extras/rtftok/rtftok.cxx
+++ b/sw/qa/extras/rtftok/rtftok.cxx
@@ -60,7 +60,7 @@ using rtl::OUString;
 using rtl::OUStringBuffer;
 using namespace com::sun::star;
 
-class RtfModelTest : public test::BootstrapFixture, public unotest::MacrosTest
+class Test : public test::BootstrapFixture, public unotest::MacrosTest
 {
 public:
     virtual void setUp();
@@ -92,7 +92,7 @@ public:
     void testFdo44211();
     void testFdo48037();
 
-    CPPUNIT_TEST_SUITE(RtfModelTest);
+    CPPUNIT_TEST_SUITE(Test);
 #if !defined(MACOSX) && !defined(WNT)
     CPPUNIT_TEST(testFdo45553);
     CPPUNIT_TEST(testN192129);
@@ -132,12 +132,12 @@ private:
     uno::Reference<lang::XComponent> mxComponent;
 };
 
-void RtfModelTest::load(const OUString& rFilename)
+void Test::load(const OUString& rFilename)
 {
     mxComponent = loadFromDesktop(getURLFromSrc("/sw/qa/extras/rtftok/data/") + rFilename);
 }
 
-int RtfModelTest::getLength()
+int Test::getLength()
 {
     uno::Reference<text::XTextDocument> xTextDocument(mxComponent, uno::UNO_QUERY);
     uno::Reference<container::XEnumerationAccess> xParaEnumAccess(xTextDocument->getText(), uno::UNO_QUERY);
@@ -156,7 +156,7 @@ int RtfModelTest::getLength()
     return aBuf.getLength();
 }
 
-int RtfModelTest::getPages()
+int Test::getPages()
 {
     uno::Reference<frame::XModel> xModel(mxComponent, uno::UNO_QUERY);
     uno::Reference<text::XTextViewCursorSupplier> xTextViewCursorSupplier(xModel->getCurrentController(), uno::UNO_QUERY);
@@ -165,7 +165,7 @@ int RtfModelTest::getPages()
     return xCursor->getPage();
 }
 
-void RtfModelTest::setUp()
+void Test::setUp()
 {
     test::BootstrapFixture::setUp();
 
@@ -173,7 +173,7 @@ void RtfModelTest::setUp()
     CPPUNIT_ASSERT(mxDesktop.is());
 }
 
-void RtfModelTest::tearDown()
+void Test::tearDown()
 {
     if (mxComponent.is())
         mxComponent->dispose();
@@ -181,7 +181,7 @@ void RtfModelTest::tearDown()
     test::BootstrapFixture::tearDown();
 }
 
-void RtfModelTest::testFdo45553()
+void Test::testFdo45553()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo45553.rtf")));
 
@@ -216,7 +216,7 @@ void RtfModelTest::testFdo45553()
     }
 }
 
-void RtfModelTest::testN192129()
+void Test::testN192129()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("n192129.rtf")));
 
@@ -234,13 +234,13 @@ void RtfModelTest::testN192129()
     CPPUNIT_ASSERT_EQUAL(sal_Int32(aExpectedSize.Height()), aActualSize.Height);
 }
 
-void RtfModelTest::testFdo45543()
+void Test::testFdo45543()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo45543.rtf")));
     CPPUNIT_ASSERT_EQUAL(5, getLength());
 }
 
-void RtfModelTest::testN695479()
+void Test::testN695479()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("n695479.rtf")));
 
@@ -301,13 +301,13 @@ void RtfModelTest::testN695479()
     CPPUNIT_ASSERT(bDrawFound);
 }
 
-void RtfModelTest::testFdo42465()
+void Test::testFdo42465()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo42465.rtf")));
     CPPUNIT_ASSERT_EQUAL(3, getLength());
 }
 
-void RtfModelTest::testFdo45187()
+void Test::testFdo45187()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo45187.rtf")));
 
@@ -327,7 +327,7 @@ void RtfModelTest::testFdo45187()
     CPPUNIT_ASSERT(aFirstPoint.Y != aSecondPoint.Y);
 }
 
-void RtfModelTest::testFdo46662()
+void Test::testFdo46662()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo46662.rtf")));
 
@@ -359,7 +359,7 @@ void RtfModelTest::testFdo46662()
     }
 }
 
-void RtfModelTest::testN750757()
+void Test::testN750757()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("n750757.rtf")));
     uno::Reference<text::XTextDocument> xTextDocument(mxComponent, uno::UNO_QUERY);
@@ -378,7 +378,7 @@ void RtfModelTest::testN750757()
     CPPUNIT_ASSERT_EQUAL(sal_Bool(true), bValue);
 }
 
-void RtfModelTest::testFdo45563()
+void Test::testFdo45563()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo45563.rtf")));
     uno::Reference<text::XTextDocument> xTextDocument(mxComponent, uno::UNO_QUERY);
@@ -393,7 +393,7 @@ void RtfModelTest::testFdo45563()
     CPPUNIT_ASSERT_EQUAL(4, i);
 }
 
-void RtfModelTest::testFdo43965()
+void Test::testFdo43965()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo43965.rtf")));
     uno::Reference<text::XTextDocument> xTextDocument(mxComponent, uno::UNO_QUERY);
@@ -420,7 +420,7 @@ void RtfModelTest::testFdo43965()
     CPPUNIT_ASSERT_EQUAL(2, getPages());
 }
 
-void RtfModelTest::testN751020()
+void Test::testN751020()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("n751020.rtf")));
     uno::Reference<text::XTextDocument> xTextDocument(mxComponent, uno::UNO_QUERY);
@@ -433,14 +433,14 @@ void RtfModelTest::testN751020()
     CPPUNIT_ASSERT_EQUAL(sal_Int32(TWIP_TO_MM100(200)), nValue);
 }
 
-void RtfModelTest::testFdo47326()
+void Test::testFdo47326()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo47326.rtf")));
     // This was 15 only, as \super buffered text, then the contents of it got lost.
     CPPUNIT_ASSERT_EQUAL(19, getLength());
 }
 
-void RtfModelTest::testFdo47036()
+void Test::testFdo47036()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo47036.rtf")));
 
@@ -464,7 +464,7 @@ void RtfModelTest::testFdo47036()
     CPPUNIT_ASSERT_EQUAL(sal_Int32(2), xIndexAccess->getCount());
 }
 
-void RtfModelTest::testFdo46955()
+void Test::testFdo46955()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo46955.rtf")));
 
@@ -485,7 +485,7 @@ void RtfModelTest::testFdo46955()
     }
 }
 
-void RtfModelTest::testFdo45394()
+void Test::testFdo45394()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo45394.rtf")));
 
@@ -504,13 +504,13 @@ void RtfModelTest::testFdo45394()
     CPPUNIT_ASSERT_EQUAL(sal_Int32(1), xIndexAccess->getCount());
 }
 
-void RtfModelTest::testFdo48104()
+void Test::testFdo48104()
 {
     load(OUString(RTL_CONSTASCII_USTRINGPARAM("fdo48104.rtf")));
     CPPUNIT_ASSERT_EQUAL(2, getPages());
 }
 
-void RtfModelTest::testFdo47107()
+void Test::testFdo47107()
 {
     load("fdo47107.rtf");
 
@@ -522,7 +522,7 @@ void RtfModelTest::testFdo47107()
     xNumberingStyles->getByName("WWNum2");
 }
 
-void RtfModelTest::testFdo45182()
+void Test::testFdo45182()
 {
     load("fdo45182.rtf");
 
@@ -534,7 +534,7 @@ void RtfModelTest::testFdo45182()
     CPPUNIT_ASSERT_EQUAL(aExpected, xTextRange->getString());
 }
 
-void RtfModelTest::testFdo44176()
+void Test::testFdo44176()
 {
     load("fdo44176.rtf");
 
@@ -550,7 +550,7 @@ void RtfModelTest::testFdo44176()
     CPPUNIT_ASSERT_EQUAL(nFirstTop, nDefaultTop + nDefaultHeader);
 }
 
-void RtfModelTest::testFdo39053()
+void Test::testFdo39053()
 {
     load("fdo39053.rtf");
 
@@ -569,7 +569,7 @@ void RtfModelTest::testFdo39053()
     CPPUNIT_ASSERT_EQUAL(1, nAsCharacter);
 }
 
-void RtfModelTest::testFdo48356()
+void Test::testFdo48356()
 {
     load("fdo48356.rtf");
 
@@ -587,7 +587,7 @@ void RtfModelTest::testFdo48356()
     CPPUNIT_ASSERT_EQUAL(1, i);
 }
 
-void RtfModelTest::testFdo48023()
+void Test::testFdo48023()
 {
     lang::Locale aLocale;
     aLocale.Language = "ru";
@@ -610,7 +610,7 @@ void RtfModelTest::testFdo48023()
     CPPUNIT_ASSERT_EQUAL(aExpected, xTextRange->getString());
 }
 
-void RtfModelTest::testFdo48876()
+void Test::testFdo48876()
 {
     load("fdo48876.rtf");
     uno::Reference<text::XTextDocument> xTextDocument(mxComponent, uno::UNO_QUERY);
@@ -623,13 +623,13 @@ void RtfModelTest::testFdo48876()
     CPPUNIT_ASSERT_EQUAL(style::LineSpacingMode::MINIMUM, aSpacing.Mode);
 }
 
-void RtfModelTest::testFdo48193()
+void Test::testFdo48193()
 {
     load("fdo48193.rtf");
     CPPUNIT_ASSERT_EQUAL(7, getLength());
 }
 
-void RtfModelTest::testFdo44211()
+void Test::testFdo44211()
 {
     lang::Locale aLocale;
     aLocale.Language = "lt";
@@ -651,7 +651,7 @@ void RtfModelTest::testFdo44211()
     CPPUNIT_ASSERT_EQUAL(aExpected, xTextRange->getString());
 }
 
-void RtfModelTest::testFdo48037()
+void Test::testFdo48037()
 {
     load("fdo48037.rtf");
 
@@ -671,7 +671,7 @@ void RtfModelTest::testFdo48037()
     CPPUNIT_ASSERT_EQUAL(nExpected, nActual);
 }
 
-CPPUNIT_TEST_SUITE_REGISTRATION(RtfModelTest);
+CPPUNIT_TEST_SUITE_REGISTRATION(Test);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
 


More information about the Libreoffice-commits mailing list