[Libreoffice-commits] core.git: solenv/clang-format test/source

Philipp Hofer (via logerrit) logerrit at kemper.freedesktop.org
Wed Nov 18 11:05:13 UTC 2020


 solenv/clang-format/excludelist            |   20 --------
 test/source/container/xnamed.cxx           |    8 +--
 test/source/setupvcl.hxx                   |    5 --
 test/source/sheet/cellproperties.cxx       |    9 +--
 test/source/sheet/databaserange.cxx        |   45 +++++++++---------
 test/source/sheet/datapilotitem.cxx        |   10 +---
 test/source/sheet/xcelladdressable.cxx     |    7 +-
 test/source/sheet/xcellrangereferrer.cxx   |   10 ++--
 test/source/sheet/xdatabaserange.cxx       |   71 +++++++++++++----------------
 test/source/sheet/xdatapilottable.cxx      |   18 ++-----
 test/source/sheet/xgoalseek.cxx            |   13 ++---
 test/source/sheet/xsheetoperation.cxx      |   15 ++----
 test/source/sheet/xspreadsheetdocument.cxx |   13 ++---
 test/source/sheet/xsubtotaldescriptor.cxx  |   11 ++--
 test/source/sheet/xviewfreezable.cxx       |    9 +--
 test/source/sheet/xviewpane.cxx            |   11 ++--
 test/source/text/xtext.cxx                 |    5 --
 test/source/text/xtextcontent.cxx          |   15 ++----
 test/source/unoapi_test.cxx                |    9 ++-
 test/source/util/xreplaceable.cxx          |   25 +++++-----
 test/source/util/xsearchable.cxx           |   29 +++++------
 21 files changed, 158 insertions(+), 200 deletions(-)

New commits:
commit f5e3b2e83ab463064f100a9cd93f09cadaae2292
Author:     Philipp Hofer <philipp.hofer at protonmail.com>
AuthorDate: Thu Nov 12 13:22:23 2020 +0100
Commit:     Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
CommitDate: Wed Nov 18 12:04:26 2020 +0100

    tdf#123936 Formatting files in module test with clang-format
    
    Change-Id: I8b2cc4917564626432ce0219e24f253a534ce8e8
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105719
    Tested-by: Jenkins
    Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>

diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist
index 540f8de33912..872142284d0e 100644
--- a/solenv/clang-format/excludelist
+++ b/solenv/clang-format/excludelist
@@ -15092,30 +15092,20 @@ sw/source/uibase/wrtsh/wrtsh4.cxx
 sw/source/uibase/wrtsh/wrtundo.cxx
 test/source/bootstrapfixture.cxx
 test/source/calc_unoapi_test.cxx
-test/source/container/xnamed.cxx
 test/source/diff/diff.cxx
 test/source/htmltesttools.cxx
 test/source/isheadless.hxx
 test/source/screenshot_test.cxx
 test/source/setupvcl.cxx
-test/source/setupvcl.hxx
-test/source/sheet/cellproperties.cxx
-test/source/sheet/databaserange.cxx
 test/source/sheet/datapilotfield.cxx
-test/source/sheet/datapilotitem.cxx
 test/source/sheet/xarealink.cxx
 test/source/sheet/xarealinks.cxx
-test/source/sheet/xcelladdressable.cxx
 test/source/sheet/xcellrangedata.cxx
-test/source/sheet/xcellrangereferrer.cxx
 test/source/sheet/xcellrangesquery.cxx
 test/source/sheet/xcellseries.cxx
-test/source/sheet/xdatabaserange.cxx
 test/source/sheet/xdatapilotdescriptor.cxx
 test/source/sheet/xdatapilotfieldgrouping.cxx
-test/source/sheet/xdatapilottable.cxx
 test/source/sheet/xdatapilottable2.cxx
-test/source/sheet/xgoalseek.cxx
 test/source/sheet/xnamedrange.cxx
 test/source/sheet/xprintareas.cxx
 test/source/sheet/xsheetannotation.cxx
@@ -15123,26 +15113,16 @@ test/source/sheet/xsheetannotations.cxx
 test/source/sheet/xsheetannotationshapesupplier.cxx
 test/source/sheet/xsheetfilterable.cxx
 test/source/sheet/xsheetlinkable.cxx
-test/source/sheet/xsheetoperation.cxx
 test/source/sheet/xsheetoutline.cxx
 test/source/sheet/xsheetpagebreak.cxx
 test/source/sheet/xspreadsheet.cxx
-test/source/sheet/xspreadsheetdocument.cxx
 test/source/sheet/xspreadsheets.cxx
 test/source/sheet/xspreadsheets2.cxx
 test/source/sheet/xsubtotalcalculatable.cxx
-test/source/sheet/xsubtotaldescriptor.cxx
 test/source/sheet/xsubtotalfield.cxx
 test/source/sheet/xuniquecellformatrangessupplier.cxx
 test/source/sheet/xusedareacursor.cxx
-test/source/sheet/xviewfreezable.cxx
-test/source/sheet/xviewpane.cxx
 test/source/sheet/xviewsplitable.cxx
-test/source/text/xtext.cxx
-test/source/text/xtextcontent.cxx
-test/source/unoapi_test.cxx
-test/source/util/xreplaceable.cxx
-test/source/util/xsearchable.cxx
 test/source/vclbootstrapprotector.cxx
 test/source/xmltesttools.cxx
 testtools/source/bridgetest/bridgetest.cxx
diff --git a/test/source/container/xnamed.cxx b/test/source/container/xnamed.cxx
index 799011f41ebd..000a9f62e094 100644
--- a/test/source/container/xnamed.cxx
+++ b/test/source/container/xnamed.cxx
@@ -20,17 +20,17 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XNamed::testGetName()
 {
-    uno::Reference< container::XNamed > xNamed(init(), UNO_QUERY_THROW);
+    uno::Reference<container::XNamed> xNamed(init(), UNO_QUERY_THROW);
     CPPUNIT_ASSERT_EQUAL(m_aTestName, xNamed->getName());
 }
 
 void XNamed::testSetName()
 {
-    uno::Reference< container::XNamed > xNamed(init(), UNO_QUERY_THROW);
+    uno::Reference<container::XNamed> xNamed(init(), UNO_QUERY_THROW);
     OUString aTestName("NewName");
 
     xNamed->setName(aTestName);
diff --git a/test/source/setupvcl.hxx b/test/source/setupvcl.hxx
index 78d4683e50ce..5da3b19e03a6 100644
--- a/test/source/setupvcl.hxx
+++ b/test/source/setupvcl.hxx
@@ -14,11 +14,10 @@
 
 #include <test/testdllapi.hxx>
 
-namespace test {
-
+namespace test
+{
 // Calls InitVCL etc.; needed from multiple places in the test infrastructure:
 OOO_DLLPUBLIC_TEST_SETUPVCL void setUpVcl(bool forceHeadless = false);
-
 }
 
 #endif
diff --git a/test/source/sheet/cellproperties.cxx b/test/source/sheet/cellproperties.cxx
index 8650eaa85ef9..3d7908be78b2 100644
--- a/test/source/sheet/cellproperties.cxx
+++ b/test/source/sheet/cellproperties.cxx
@@ -17,11 +17,11 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void CellProperties::testVertJustify()
 {
-    uno::Reference< beans::XPropertySet > xCellRangeBase(init(),UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xCellRangeBase(init(), UNO_QUERY_THROW);
     OUString aVertJustify("VertJustify");
     uno::Any aOldVertJustify = xCellRangeBase->getPropertyValue(aVertJustify);
     sal_Int32 aValue = 0;
@@ -39,7 +39,7 @@ void CellProperties::testVertJustify()
 
 void CellProperties::testRotateReference()
 {
-    uno::Reference< beans::XPropertySet > xCellRangeBase(init(),UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xCellRangeBase(init(), UNO_QUERY_THROW);
     OUString aRotateReference("RotateReference");
     uno::Any aOldRotateReference = xCellRangeBase->getPropertyValue(aRotateReference);
     sal_Int32 aValue = 0;
@@ -54,7 +54,6 @@ void CellProperties::testRotateReference()
     std::cout << "New RotateReference value: " << aValue << std::endl;
     CPPUNIT_ASSERT_EQUAL_MESSAGE("value has not been changed", sal_Int32(3), aValue);
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/sheet/databaserange.cxx b/test/source/sheet/databaserange.cxx
index 7079c8ffa311..302d88bc6b50 100644
--- a/test/source/sheet/databaserange.cxx
+++ b/test/source/sheet/databaserange.cxx
@@ -20,11 +20,11 @@
 using namespace com::sun::star;
 using namespace com::sun::star::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void DatabaseRange::testMoveCells()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("MoveCells");
 
@@ -41,7 +41,7 @@ void DatabaseRange::testMoveCells()
 
 void DatabaseRange::testKeepFormats()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("KeepFormats");
 
@@ -58,7 +58,7 @@ void DatabaseRange::testKeepFormats()
 
 void DatabaseRange::testStripData()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("StripData");
 
@@ -75,7 +75,7 @@ void DatabaseRange::testStripData()
 
 void DatabaseRange::testAutoFilter()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("AutoFilter");
 
@@ -92,60 +92,64 @@ void DatabaseRange::testAutoFilter()
 
 void DatabaseRange::testUseFilterCriteriaSource()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("UseFilterCriteriaSource");
 
     bool bUseFilterCriteriaSource = true;
     CPPUNIT_ASSERT(xDatabaseRange->getPropertyValue(propName) >>= bUseFilterCriteriaSource);
-    CPPUNIT_ASSERT_MESSAGE("Default UseFilterCriteriaSource already changed", !bUseFilterCriteriaSource);
+    CPPUNIT_ASSERT_MESSAGE("Default UseFilterCriteriaSource already changed",
+                           !bUseFilterCriteriaSource);
 
     uno::Any aNewUseFilterCriteriaSource;
     aNewUseFilterCriteriaSource <<= true;
     xDatabaseRange->setPropertyValue(propName, aNewUseFilterCriteriaSource);
     CPPUNIT_ASSERT(xDatabaseRange->getPropertyValue(propName) >>= bUseFilterCriteriaSource);
-    CPPUNIT_ASSERT_MESSAGE("Value of UseFilterCriteriaSource wasn't changed", bUseFilterCriteriaSource);
+    CPPUNIT_ASSERT_MESSAGE("Value of UseFilterCriteriaSource wasn't changed",
+                           bUseFilterCriteriaSource);
 }
 
 void DatabaseRange::testFilterCriteriaSource()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("FilterCriteriaSource");
 
     table::CellRangeAddress cellRangeAddress;
     CPPUNIT_ASSERT(xDatabaseRange->getPropertyValue(propName) >>= cellRangeAddress);
     CPPUNIT_ASSERT_EQUAL_MESSAGE("Default RefreshPeriod already changed",
-                                 table::CellRangeAddress(0,0,0,0,0), cellRangeAddress);
+                                 table::CellRangeAddress(0, 0, 0, 0, 0), cellRangeAddress);
 
     uno::Any aFilterCriteriaSource;
-    aFilterCriteriaSource <<= table::CellRangeAddress(1,1,1,1,1);
+    aFilterCriteriaSource <<= table::CellRangeAddress(1, 1, 1, 1, 1);
     xDatabaseRange->setPropertyValue(propName, aFilterCriteriaSource);
     CPPUNIT_ASSERT(xDatabaseRange->getPropertyValue(propName) >>= cellRangeAddress);
     CPPUNIT_ASSERT_EQUAL_MESSAGE("Value of FilterCriteriaSource wasn't changed",
-                                 table::CellRangeAddress(1,1,1,1,1), cellRangeAddress);
+                                 table::CellRangeAddress(1, 1, 1, 1, 1), cellRangeAddress);
 }
 
 void DatabaseRange::testRefreshPeriod()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("RefreshPeriod");
 
     sal_Int32 aRefreshPeriod = 1;
     CPPUNIT_ASSERT(xDatabaseRange->getPropertyValue(propName) >>= aRefreshPeriod);
-    CPPUNIT_ASSERT_EQUAL_MESSAGE("Default RefreshPeriod already changed", sal_Int32(0), aRefreshPeriod);
+    CPPUNIT_ASSERT_EQUAL_MESSAGE("Default RefreshPeriod already changed", sal_Int32(0),
+                                 aRefreshPeriod);
 
     uno::Any aNewRefreshPeriod;
     aNewRefreshPeriod <<= static_cast<sal_Int32>(42);
     xDatabaseRange->setPropertyValue(propName, aNewRefreshPeriod);
     CPPUNIT_ASSERT(xDatabaseRange->getPropertyValue(propName) >>= aRefreshPeriod);
-    CPPUNIT_ASSERT_EQUAL_MESSAGE("Value of RefreshPeriod wasn't changed", sal_Int32(42), aRefreshPeriod);
+    CPPUNIT_ASSERT_EQUAL_MESSAGE("Value of RefreshPeriod wasn't changed", sal_Int32(42),
+                                 aRefreshPeriod);
 }
 
 void DatabaseRange::testFromSelection()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("FromSelection");
 
@@ -162,7 +166,7 @@ void DatabaseRange::testFromSelection()
 
 void DatabaseRange::testTokenIndex()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("TokenIndex");
 
@@ -179,7 +183,7 @@ void DatabaseRange::testTokenIndex()
 
 void DatabaseRange::testTotalsRow()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("TotalsRow");
 
@@ -196,7 +200,7 @@ void DatabaseRange::testTotalsRow()
 
 void DatabaseRange::testContainsHeader()
 {
-    uno::Reference< beans::XPropertySet > xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<beans::XPropertySet> xDatabaseRange(init("DataArea"), UNO_QUERY_THROW);
 
     const OUString propName("ContainsHeader");
 
@@ -210,7 +214,6 @@ void DatabaseRange::testContainsHeader()
     CPPUNIT_ASSERT(xDatabaseRange->getPropertyValue(propName) >>= bContainsHeader);
     CPPUNIT_ASSERT_MESSAGE("Value of ContainsHeader wasn't changed", !bContainsHeader);
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/test/source/sheet/datapilotitem.cxx b/test/source/sheet/datapilotitem.cxx
index ac505afb7ff5..4b2299c0068f 100644
--- a/test/source/sheet/datapilotitem.cxx
+++ b/test/source/sheet/datapilotitem.cxx
@@ -18,12 +18,11 @@
 using namespace com::sun::star;
 using namespace com::sun::star::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void DataPilotItem::testProperties()
 {
-    uno::Reference< beans::XPropertySet > xItem(init(), UNO_QUERY_THROW);
-
+    uno::Reference<beans::XPropertySet> xItem(init(), UNO_QUERY_THROW);
 
     const OUString propNameIS("IsHidden");
 
@@ -37,7 +36,6 @@ void DataPilotItem::testProperties()
     CPPUNIT_ASSERT(xItem->getPropertyValue(propNameIS) >>= bIsHidden);
     CPPUNIT_ASSERT_MESSAGE("Value of IsHidden wasn't changed", !bIsHidden);
 
-
     const OUString propNameSD("ShowDetail");
 
     bool bShowDetail = false;
@@ -50,7 +48,6 @@ void DataPilotItem::testProperties()
     CPPUNIT_ASSERT(xItem->getPropertyValue(propNameSD) >>= bShowDetail);
     CPPUNIT_ASSERT_MESSAGE("Value of ShowDetail wasn't changed", bShowDetail);
 
-
     sal_Int32 nPosition = 42;
     CPPUNIT_ASSERT(xItem->getPropertyValue("Position") >>= nPosition);
     CPPUNIT_ASSERT_EQUAL_MESSAGE("Default Position already changed", sal_Int32(0), nPosition);
@@ -62,7 +59,6 @@ void DataPilotItem::testProperties()
     //CPPUNIT_ASSERT(xItem->getPropertyValue(propNameP) >>= nPosition);
     //CPPUNIT_ASSERT_EQUAL_MESSAGE("Value of Position wasn't changed", sal_Int32(42), nPosition);
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/test/source/sheet/xcelladdressable.cxx b/test/source/sheet/xcelladdressable.cxx
index fe70f8877724..e42809170518 100644
--- a/test/source/sheet/xcelladdressable.cxx
+++ b/test/source/sheet/xcelladdressable.cxx
@@ -18,18 +18,17 @@
 using namespace com::sun::star;
 using namespace com::sun::star::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XCellAddressable::testGetCellAddress()
 {
-    uno::Reference< sheet::XCellAddressable > xCellAddressable(init(), UNO_QUERY_THROW);
+    uno::Reference<sheet::XCellAddressable> xCellAddressable(init(), UNO_QUERY_THROW);
     table::CellAddress xCellAddress = xCellAddressable->getCellAddress();
     table::CellAddress defaultCellAddress(0, 2, 3);
 
     CPPUNIT_ASSERT_EQUAL_MESSAGE("getCellAddress() didn't returned default cell address",
                                  defaultCellAddress, xCellAddress);
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/sheet/xcellrangereferrer.cxx b/test/source/sheet/xcellrangereferrer.cxx
index e232c565d2b6..575bee05e648 100644
--- a/test/source/sheet/xcellrangereferrer.cxx
+++ b/test/source/sheet/xcellrangereferrer.cxx
@@ -19,14 +19,14 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XCellRangeReferrer::testGetReferredCells()
 {
-    uno::Reference< sheet::XCellRangeReferrer > xReferrer(init(), UNO_QUERY_THROW);
-    uno::Reference< table::XCellRange > xReferredRange = xReferrer->getReferredCells();
+    uno::Reference<sheet::XCellRangeReferrer> xReferrer(init(), UNO_QUERY_THROW);
+    uno::Reference<table::XCellRange> xReferredRange = xReferrer->getReferredCells();
 
-    uno::Reference< sheet::XCellRangeAddressable > xAddressable( xReferredRange, UNO_QUERY_THROW );
+    uno::Reference<sheet::XCellRangeAddressable> xAddressable(xReferredRange, UNO_QUERY_THROW);
     table::CellRangeAddress aCellRange = xAddressable->getRangeAddress();
 
     CPPUNIT_ASSERT_EQUAL(aCellRange, getCellRange());
diff --git a/test/source/sheet/xdatabaserange.cxx b/test/source/sheet/xdatabaserange.cxx
index 933425c040d6..2c45ba0fbf0a 100644
--- a/test/source/sheet/xdatabaserange.cxx
+++ b/test/source/sheet/xdatabaserange.cxx
@@ -26,14 +26,14 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 /**
  * tests setDataArea and getDataArea
  */
 void XDatabaseRange::testDataArea()
 {
-    uno::Reference< sheet::XDatabaseRange > xDBRange(init("DataArea"), UNO_QUERY_THROW);
+    uno::Reference<sheet::XDatabaseRange> xDBRange(init("DataArea"), UNO_QUERY_THROW);
 
     table::CellRangeAddress aCellAddress;
     aCellAddress.Sheet = 0;
@@ -43,24 +43,24 @@ void XDatabaseRange::testDataArea()
     aCellAddress.EndRow = 5;
     xDBRange->setDataArea(aCellAddress);
     table::CellRangeAddress aValue = xDBRange->getDataArea();
-    CPPUNIT_ASSERT_EQUAL( aCellAddress.Sheet, aValue.Sheet );
-    CPPUNIT_ASSERT_EQUAL( aCellAddress.StartRow, aValue.StartRow );
-    CPPUNIT_ASSERT_EQUAL( aCellAddress.EndRow, aValue.EndRow );
-    CPPUNIT_ASSERT_EQUAL( aCellAddress.StartColumn, aValue.StartColumn );
-    CPPUNIT_ASSERT_EQUAL( aCellAddress.EndColumn, aValue.EndColumn );
+    CPPUNIT_ASSERT_EQUAL(aCellAddress.Sheet, aValue.Sheet);
+    CPPUNIT_ASSERT_EQUAL(aCellAddress.StartRow, aValue.StartRow);
+    CPPUNIT_ASSERT_EQUAL(aCellAddress.EndRow, aValue.EndRow);
+    CPPUNIT_ASSERT_EQUAL(aCellAddress.StartColumn, aValue.StartColumn);
+    CPPUNIT_ASSERT_EQUAL(aCellAddress.EndColumn, aValue.EndColumn);
 }
 
 void XDatabaseRange::testGetSubtotalDescriptor()
 {
-    uno::Reference< sheet::XDatabaseRange > xDBRange(init("SubtotalDescriptor"), UNO_QUERY_THROW);
-    uno::Reference< sheet::XSubTotalDescriptor> xSubtotalDescr = xDBRange->getSubTotalDescriptor();
+    uno::Reference<sheet::XDatabaseRange> xDBRange(init("SubtotalDescriptor"), UNO_QUERY_THROW);
+    uno::Reference<sheet::XSubTotalDescriptor> xSubtotalDescr = xDBRange->getSubTotalDescriptor();
     CPPUNIT_ASSERT(xSubtotalDescr.is());
 }
 
 void XDatabaseRange::testGetSortDescriptor()
 {
-    uno::Reference< sheet::XDatabaseRange > xDBRange(init("SortDescriptor"), UNO_QUERY_THROW);
-    const uno::Sequence< beans::PropertyValue > xSortDescr = xDBRange->getSortDescriptor();
+    uno::Reference<sheet::XDatabaseRange> xDBRange(init("SortDescriptor"), UNO_QUERY_THROW);
+    const uno::Sequence<beans::PropertyValue> xSortDescr = xDBRange->getSortDescriptor();
     for (const beans::PropertyValue& aProp : xSortDescr)
     {
         //std::cout << "Prop " << i << " Name: " << OUString(aProp.Name) << std::endl;
@@ -82,11 +82,9 @@ void XDatabaseRange::testGetSortDescriptor()
             sal_Int32 nMaxFieldCount = 0;
             aProp.Value >>= nMaxFieldCount;
             std::cout << "Value: " << nMaxFieldCount << std::endl;
-
         }
         else if (aProp.Name == "SortFields")
         {
-
         }
         else if (aProp.Name == "BindFormatsToContent")
         {
@@ -102,14 +100,12 @@ void XDatabaseRange::testGetSortDescriptor()
         }
         else if (aProp.Name == "OutputPosition")
         {
-
         }
         else if (aProp.Name == "IsUserListEnabled")
         {
-            bool bIsUserListEnabled  = true;
+            bool bIsUserListEnabled = true;
             aProp.Value >>= bIsUserListEnabled;
             CPPUNIT_ASSERT(!bIsUserListEnabled);
-
         }
         else if (aProp.Name == "UserListIndex")
         {
@@ -122,39 +118,39 @@ void XDatabaseRange::testGetSortDescriptor()
 
 void XDatabaseRange::testGetFilterDescriptor()
 {
-    uno::Reference< sheet::XDatabaseRange > xDBRange( init("FilterDescriptor"), UNO_QUERY_THROW);
-    uno::Reference< uno::XInterface > xFilterDescr( xDBRange->getFilterDescriptor(), UNO_QUERY_THROW);
+    uno::Reference<sheet::XDatabaseRange> xDBRange(init("FilterDescriptor"), UNO_QUERY_THROW);
+    uno::Reference<uno::XInterface> xFilterDescr(xDBRange->getFilterDescriptor(), UNO_QUERY_THROW);
 }
 
 void XDatabaseRange::testGetImportDescriptor()
 {
-    uno::Reference< sheet::XDatabaseRange > xDBRange( init("ImportDescriptor"), UNO_QUERY_THROW);
-    uno::Sequence< beans::PropertyValue > xImportDescr = xDBRange->getImportDescriptor();
-    (void) xImportDescr;
+    uno::Reference<sheet::XDatabaseRange> xDBRange(init("ImportDescriptor"), UNO_QUERY_THROW);
+    uno::Sequence<beans::PropertyValue> xImportDescr = xDBRange->getImportDescriptor();
+    (void)xImportDescr;
 }
 
 void XDatabaseRange::testRefresh()
 {
-    uno::Reference< sheet::XDatabaseRange > xDBRange( init("Refresh"), UNO_QUERY_THROW);
+    uno::Reference<sheet::XDatabaseRange> xDBRange(init("Refresh"), UNO_QUERY_THROW);
 
     const sal_Int32 nCol = 0;
     OUString aHidden("IsVisible");
-    uno::Reference< sheet::XCellRangeReferrer > xCellRangeReferrer(xDBRange, UNO_QUERY_THROW);
-    uno::Reference< table::XCellRange > xCellRange = xCellRangeReferrer->getReferredCells();
+    uno::Reference<sheet::XCellRangeReferrer> xCellRangeReferrer(xDBRange, UNO_QUERY_THROW);
+    uno::Reference<table::XCellRange> xCellRange = xCellRangeReferrer->getReferredCells();
 
     for (sal_Int32 i = 1; i < 5; ++i)
     {
-        uno::Reference< table::XCell > xCell = xCellRange->getCellByPosition(nCol, i);
+        uno::Reference<table::XCell> xCell = xCellRange->getCellByPosition(nCol, i);
         xCell->setValue(0);
     }
 
     for (sal_Int32 i = 2; i < 5; ++i)
     {
-        uno::Reference< table::XColumnRowRange > xColRowRange(xCellRange, UNO_QUERY_THROW);
-        uno::Reference< table::XTableRows > xRows = xColRowRange->getRows();
-        uno::Reference< table::XCellRange > xRow(xRows->getByIndex(i), UNO_QUERY_THROW);
-        uno::Reference< beans::XPropertySet > xPropRow(xRow, UNO_QUERY_THROW);
-        Any aAny = xPropRow->getPropertyValue( aHidden );
+        uno::Reference<table::XColumnRowRange> xColRowRange(xCellRange, UNO_QUERY_THROW);
+        uno::Reference<table::XTableRows> xRows = xColRowRange->getRows();
+        uno::Reference<table::XCellRange> xRow(xRows->getByIndex(i), UNO_QUERY_THROW);
+        uno::Reference<beans::XPropertySet> xPropRow(xRow, UNO_QUERY_THROW);
+        Any aAny = xPropRow->getPropertyValue(aHidden);
 
         CPPUNIT_ASSERT(aAny.get<bool>());
     }
@@ -164,18 +160,15 @@ void XDatabaseRange::testRefresh()
 
     for (sal_Int32 i = 1; i < 5; ++i)
     {
-        uno::Reference< table::XColumnRowRange > xColRowRange(xCellRange, UNO_QUERY_THROW);
-        uno::Reference< table::XTableRows > xRows = xColRowRange->getRows();
-        uno::Reference< table::XCellRange > xRow(xRows->getByIndex(i), UNO_QUERY_THROW);
-        uno::Reference< beans::XPropertySet > xPropRow(xRow, UNO_QUERY_THROW);
-        Any aAny = xPropRow->getPropertyValue( aHidden );
+        uno::Reference<table::XColumnRowRange> xColRowRange(xCellRange, UNO_QUERY_THROW);
+        uno::Reference<table::XTableRows> xRows = xColRowRange->getRows();
+        uno::Reference<table::XCellRange> xRow(xRows->getByIndex(i), UNO_QUERY_THROW);
+        uno::Reference<beans::XPropertySet> xPropRow(xRow, UNO_QUERY_THROW);
+        Any aAny = xPropRow->getPropertyValue(aHidden);
 
         CPPUNIT_ASSERT(!aAny.get<bool>());
     }
-
-
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/sheet/xdatapilottable.cxx b/test/source/sheet/xdatapilottable.cxx
index 5934532dcc85..4cfff74ed5c1 100644
--- a/test/source/sheet/xdatapilottable.cxx
+++ b/test/source/sheet/xdatapilottable.cxx
@@ -16,24 +16,23 @@ using namespace css::uno;
 
 namespace apitest
 {
-
 void XDataPilotTable::testGetOutputRange()
 {
-    uno::Reference< sheet::XDataPilotTable > xDPTable(init(),UNO_QUERY_THROW);
+    uno::Reference<sheet::XDataPilotTable> xDPTable(init(), UNO_QUERY_THROW);
 
     table::CellRangeAddress aRange = xDPTable->getOutputRange();
-    CPPUNIT_ASSERT_EQUAL( sal_Int16(0), aRange.Sheet );
-    CPPUNIT_ASSERT_EQUAL( sal_Int32(7), aRange.StartColumn );
-    CPPUNIT_ASSERT_EQUAL( sal_Int32(8), aRange.StartRow );
+    CPPUNIT_ASSERT_EQUAL(sal_Int16(0), aRange.Sheet);
+    CPPUNIT_ASSERT_EQUAL(sal_Int32(7), aRange.StartColumn);
+    CPPUNIT_ASSERT_EQUAL(sal_Int32(8), aRange.StartRow);
 }
 
 void XDataPilotTable::testRefresh()
 {
-    uno::Reference< sheet::XDataPilotTable > xDPTable(init(),UNO_QUERY_THROW);
+    uno::Reference<sheet::XDataPilotTable> xDPTable(init(), UNO_QUERY_THROW);
     std::cout << "xCellForChange: Old Value: " << xCellForChange->getValue() << std::endl;
     std::cout << "xCellForCheck: Old Value: " << xCellForCheck->getValue() << std::endl;
     double aOldData = xCellForCheck->getValue();
-    xCellForChange->setValue( 5 );
+    xCellForChange->setValue(5);
 
     xDPTable->refresh();
     xDPTable->refresh();
@@ -43,10 +42,7 @@ void XDataPilotTable::testRefresh()
     CPPUNIT_ASSERT_MESSAGE("value needs to change", aOldData != aNewData);
 }
 
-XDataPilotTable::~XDataPilotTable()
-{
-}
-
+XDataPilotTable::~XDataPilotTable() {}
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/sheet/xgoalseek.cxx b/test/source/sheet/xgoalseek.cxx
index 986af40561d3..b1de09d2e22b 100644
--- a/test/source/sheet/xgoalseek.cxx
+++ b/test/source/sheet/xgoalseek.cxx
@@ -17,21 +17,20 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XGoalSeek::testSeekGoal()
 {
-    uno::Reference< sheet::XGoalSeek > xGoalSeek(init(), UNO_QUERY_THROW);
+    uno::Reference<sheet::XGoalSeek> xGoalSeek(init(), UNO_QUERY_THROW);
 
-    table::CellAddress aFormulaAddr(0,3,5);
-    table::CellAddress aVariableAddr(0,3,4);
+    table::CellAddress aFormulaAddr(0, 3, 5);
+    table::CellAddress aVariableAddr(0, 3, 4);
     sheet::GoalResult aResult = xGoalSeek->seekGoal(aFormulaAddr, aVariableAddr, "4");
 
     double nDivergence = 0.01;
-    CPPUNIT_ASSERT( aResult.Divergence < nDivergence );
+    CPPUNIT_ASSERT(aResult.Divergence < nDivergence);
     CPPUNIT_ASSERT_DOUBLES_EQUAL(16, aResult.Result, nDivergence);
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/sheet/xsheetoperation.cxx b/test/source/sheet/xsheetoperation.cxx
index 22015a40d17d..6f8496482eac 100644
--- a/test/source/sheet/xsheetoperation.cxx
+++ b/test/source/sheet/xsheetoperation.cxx
@@ -19,26 +19,25 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XSheetOperation::testClearContents()
 {
-    uno::Reference< sheet::XSheetOperation > xSheetOperation(init(), UNO_QUERY_THROW);
+    uno::Reference<sheet::XSheetOperation> xSheetOperation(init(), UNO_QUERY_THROW);
 
-    xSheetOperation->clearContents( sheet::CellFlags::VALUE | sheet::CellFlags::FORMULA );
+    xSheetOperation->clearContents(sheet::CellFlags::VALUE | sheet::CellFlags::FORMULA);
 
-    double sum = xSheetOperation->computeFunction( sheet::GeneralFunction_SUM );
+    double sum = xSheetOperation->computeFunction(sheet::GeneralFunction_SUM);
     CPPUNIT_ASSERT_EQUAL_MESSAGE("Unable to clean contents", 0.0, sum);
 }
 
 void XSheetOperation::testComputeFunction()
 {
-    uno::Reference< sheet::XSheetOperation > xSheetOperation(init(), UNO_QUERY_THROW);
+    uno::Reference<sheet::XSheetOperation> xSheetOperation(init(), UNO_QUERY_THROW);
 
-    double count = xSheetOperation->computeFunction( sheet::GeneralFunction_COUNT );
+    double count = xSheetOperation->computeFunction(sheet::GeneralFunction_COUNT);
     CPPUNIT_ASSERT_MESSAGE("Unable to compute function", count >= 0.0);
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/sheet/xspreadsheetdocument.cxx b/test/source/sheet/xspreadsheetdocument.cxx
index fd8f66ab54d8..d808d8b31f6d 100644
--- a/test/source/sheet/xspreadsheetdocument.cxx
+++ b/test/source/sheet/xspreadsheetdocument.cxx
@@ -16,18 +16,17 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XSpreadsheetDocument::testGetSheets()
 {
-    uno::Reference< sheet::XSpreadsheetDocument > xSpreadsheetDoc(init(), UNO_QUERY_THROW);
-    uno::Reference< sheet::XSpreadsheets > xSheets = xSpreadsheetDoc->getSheets();
+    uno::Reference<sheet::XSpreadsheetDocument> xSpreadsheetDoc(init(), UNO_QUERY_THROW);
+    uno::Reference<sheet::XSpreadsheets> xSheets = xSpreadsheetDoc->getSheets();
     CPPUNIT_ASSERT(xSheets.is());
 
-    uno::Reference< container::XIndexAccess > xIA(xSheets, UNO_QUERY_THROW);
-    CPPUNIT_ASSERT_EQUAL( mnSheets, xIA->getCount() );
+    uno::Reference<container::XIndexAccess> xIA(xSheets, UNO_QUERY_THROW);
+    CPPUNIT_ASSERT_EQUAL(mnSheets, xIA->getCount());
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/sheet/xsubtotaldescriptor.cxx b/test/source/sheet/xsubtotaldescriptor.cxx
index fa5aca6345b0..87c2083ef9f5 100644
--- a/test/source/sheet/xsubtotaldescriptor.cxx
+++ b/test/source/sheet/xsubtotaldescriptor.cxx
@@ -21,13 +21,13 @@
 using namespace com::sun::star;
 using namespace com::sun::star::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XSubTotalDescriptor::testAddNew()
 {
-    uno::Reference< sheet::XSubTotalDescriptor > xSTD(init(), uno::UNO_QUERY_THROW);
+    uno::Reference<sheet::XSubTotalDescriptor> xSTD(init(), uno::UNO_QUERY_THROW);
 
-    uno::Sequence< sheet::SubTotalColumn > xCols;
+    uno::Sequence<sheet::SubTotalColumn> xCols;
     xCols.realloc(1);
     xCols[0].Column = 5;
     xCols[0].Function = sheet::GeneralFunction_SUM;
@@ -37,11 +37,10 @@ void XSubTotalDescriptor::testAddNew()
 
 void XSubTotalDescriptor::testClear()
 {
-    uno::Reference< sheet::XSubTotalDescriptor > xSTD(init(), UNO_QUERY_THROW);
+    uno::Reference<sheet::XSubTotalDescriptor> xSTD(init(), UNO_QUERY_THROW);
 
     CPPUNIT_ASSERT_NO_THROW_MESSAGE("Unable to clear XSubTotalDescriptor", xSTD->clear());
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/test/source/sheet/xviewfreezable.cxx b/test/source/sheet/xviewfreezable.cxx
index 4a478f1ef149..2e13ffd294f0 100644
--- a/test/source/sheet/xviewfreezable.cxx
+++ b/test/source/sheet/xviewfreezable.cxx
@@ -16,18 +16,17 @@
 using namespace com::sun::star;
 using namespace com::sun::star::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XViewFreezable::testFreeze()
 {
-    uno::Reference< sheet::XViewFreezable > xViewFreezable(init(), UNO_QUERY_THROW);
+    uno::Reference<sheet::XViewFreezable> xViewFreezable(init(), UNO_QUERY_THROW);
 
     CPPUNIT_ASSERT_MESSAGE("View has already frozen panes", !xViewFreezable->hasFrozenPanes());
 
-    xViewFreezable->freezeAtPosition(1,1);
+    xViewFreezable->freezeAtPosition(1, 1);
     CPPUNIT_ASSERT_MESSAGE("Unable to freeze pane", xViewFreezable->hasFrozenPanes());
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/test/source/sheet/xviewpane.cxx b/test/source/sheet/xviewpane.cxx
index 5ea508bf82bf..a10c59d9c0b8 100644
--- a/test/source/sheet/xviewpane.cxx
+++ b/test/source/sheet/xviewpane.cxx
@@ -16,12 +16,12 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XViewPane::testFirstVisibleColumn()
 {
     sal_Int32 nCol = 5;
-    uno::Reference < sheet::XViewPane > xViewPane(init(),UNO_QUERY_THROW);
+    uno::Reference<sheet::XViewPane> xViewPane(init(), UNO_QUERY_THROW);
     xViewPane->setFirstVisibleColumn(nCol);
     CPPUNIT_ASSERT_EQUAL(xViewPane->getFirstVisibleColumn(), nCol);
 }
@@ -29,7 +29,7 @@ void XViewPane::testFirstVisibleColumn()
 void XViewPane::testFirstVisibleRow()
 {
     sal_Int32 nRow = 3;
-    uno::Reference < sheet::XViewPane > xViewPane(init(),UNO_QUERY_THROW);
+    uno::Reference<sheet::XViewPane> xViewPane(init(), UNO_QUERY_THROW);
     xViewPane->setFirstVisibleRow(nRow);
     CPPUNIT_ASSERT_EQUAL(xViewPane->getFirstVisibleRow(), nRow);
 }
@@ -38,7 +38,7 @@ void XViewPane::testVisibleRange()
 {
     constexpr sal_Int32 nCol = 5;
     constexpr sal_Int32 nRow = 3;
-    uno::Reference < sheet::XViewPane > xViewPane(init(),UNO_QUERY_THROW);
+    uno::Reference<sheet::XViewPane> xViewPane(init(), UNO_QUERY_THROW);
     xViewPane->setFirstVisibleColumn(nCol);
     xViewPane->setFirstVisibleRow(nRow);
 
@@ -47,7 +47,6 @@ void XViewPane::testVisibleRange()
     CPPUNIT_ASSERT_EQUAL(nRow, aCellRangeAddress.StartRow);
     CPPUNIT_ASSERT_EQUAL(nCol, aCellRangeAddress.StartColumn);
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/text/xtext.cxx b/test/source/text/xtext.cxx
index 6ab646d0aa5e..6f6274156012 100644
--- a/test/source/text/xtext.cxx
+++ b/test/source/text/xtext.cxx
@@ -12,8 +12,8 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 XText::~XText() {}
 
 void XText::testInsertRemoveTextContent()
@@ -24,7 +24,6 @@ void XText::testInsertRemoveTextContent()
     xText->insertTextContent(xCursor, getTextContent(), false);
     xText->removeTextContent(getTextContent());
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/text/xtextcontent.cxx b/test/source/text/xtextcontent.cxx
index b4b60aaead52..762584e887d1 100644
--- a/test/source/text/xtextcontent.cxx
+++ b/test/source/text/xtextcontent.cxx
@@ -16,21 +16,21 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XTextContent::testGetAnchor()
 {
-    uno::Reference< text::XTextContent > xTextContent(init(), UNO_QUERY_THROW);
-    uno::Reference< uno::XInterface > xAnchor(xTextContent->getAnchor());
+    uno::Reference<text::XTextContent> xTextContent(init(), UNO_QUERY_THROW);
+    uno::Reference<uno::XInterface> xAnchor(xTextContent->getAnchor());
     CPPUNIT_ASSERT(xAnchor.is());
 }
 
 void XTextContent::testAttach()
 {
-    uno::Reference< text::XTextContent > xTextContent(init(), UNO_QUERY_THROW);
+    uno::Reference<text::XTextContent> xTextContent(init(), UNO_QUERY_THROW);
 
-    uno::Reference< text::XTextContent > xContent(getTextContent(), UNO_SET_THROW);
-    uno::Reference< text::XTextRange > xRange(getTextRange(), UNO_SET_THROW);
+    uno::Reference<text::XTextContent> xContent(getTextContent(), UNO_SET_THROW);
+    uno::Reference<text::XTextRange> xRange(getTextRange(), UNO_SET_THROW);
 
     try
     {
@@ -52,7 +52,6 @@ void XTextContent::testAttach()
             CPPUNIT_ASSERT(false);
     }
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/unoapi_test.cxx b/test/source/unoapi_test.cxx
index 8921b6d01155..6147609f3f42 100644
--- a/test/source/unoapi_test.cxx
+++ b/test/source/unoapi_test.cxx
@@ -17,7 +17,7 @@ using namespace css;
 using namespace css::uno;
 
 UnoApiTest::UnoApiTest(const OUString& path)
-      : m_aBaseString(path)
+    : m_aBaseString(path)
 {
 }
 
@@ -25,7 +25,8 @@ void UnoApiTest::setUp()
 {
     test::BootstrapFixture::setUp();
 
-    mxDesktop = css::frame::Desktop::create( comphelper::getComponentContext(getMultiServiceFactory()) );
+    mxDesktop
+        = css::frame::Desktop::create(comphelper::getComponentContext(getMultiServiceFactory()));
     CPPUNIT_ASSERT_MESSAGE("no desktop!", mxDesktop.is());
 }
 
@@ -34,9 +35,9 @@ void UnoApiTest::createFileURL(const OUString& aFileBase, OUString& rFilePath)
     rFilePath = m_directories.getSrcRootURL() + m_aBaseString + "/" + aFileBase;
 }
 
-void UnoApiTest::closeDocument( uno::Reference< lang::XComponent > const & xDocument )
+void UnoApiTest::closeDocument(uno::Reference<lang::XComponent> const& xDocument)
 {
-    uno::Reference< util::XCloseable > xCloseable(xDocument, UNO_QUERY_THROW);
+    uno::Reference<util::XCloseable> xCloseable(xDocument, UNO_QUERY_THROW);
     xCloseable->close(false);
 }
 
diff --git a/test/source/util/xreplaceable.cxx b/test/source/util/xreplaceable.cxx
index ac9d1a4dc66d..4e315c6653da 100644
--- a/test/source/util/xreplaceable.cxx
+++ b/test/source/util/xreplaceable.cxx
@@ -21,27 +21,29 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XReplaceable::testCreateReplaceDescriptor()
 {
-    uno::Reference< util::XReplaceable > xReplaceable(init(), UNO_QUERY_THROW);
-    uno::Reference< util::XReplaceDescriptor> xReplaceDescr = xReplaceable->createReplaceDescriptor();
+    uno::Reference<util::XReplaceable> xReplaceable(init(), UNO_QUERY_THROW);
+    uno::Reference<util::XReplaceDescriptor> xReplaceDescr
+        = xReplaceable->createReplaceDescriptor();
     CPPUNIT_ASSERT(xReplaceDescr.is());
 }
 
 void XReplaceable::testReplaceAll()
 {
     std::cout << "testReplaceAll" << std::endl;
-    uno::Reference< util::XReplaceable > xReplaceable(init(), UNO_QUERY_THROW);
-    uno::Reference< util::XReplaceDescriptor> xReplaceDescr = xReplaceable->createReplaceDescriptor();
+    uno::Reference<util::XReplaceable> xReplaceable(init(), UNO_QUERY_THROW);
+    uno::Reference<util::XReplaceDescriptor> xReplaceDescr
+        = xReplaceable->createReplaceDescriptor();
     CPPUNIT_ASSERT(xReplaceDescr.is());
 
-    uno::Reference< util::XSearchDescriptor > xSearchDescr = xReplaceable->createSearchDescriptor();
+    uno::Reference<util::XSearchDescriptor> xSearchDescr = xReplaceable->createSearchDescriptor();
     xSearchDescr->setSearchString(maSearchString);
 
     //check that at least one object is there that will be replaced
-    uno::Reference< uno::XInterface > xElement = xReplaceable->findFirst(xSearchDescr);
+    uno::Reference<uno::XInterface> xElement = xReplaceable->findFirst(xSearchDescr);
     CPPUNIT_ASSERT(xElement.is());
 
     //check that there is none object with the replace string
@@ -53,7 +55,8 @@ void XReplaceable::testReplaceAll()
     xReplaceDescr->setReplaceString(maReplaceString);
 
     callgrindStart();
-    xReplaceable->replaceAll(uno::Reference< util::XSearchDescriptor >(xReplaceDescr, UNO_QUERY_THROW));
+    xReplaceable->replaceAll(
+        uno::Reference<util::XSearchDescriptor>(xReplaceDescr, UNO_QUERY_THROW));
     callgrindDump("test:replace_all");
 
     //check that now at least one element is found
@@ -68,7 +71,8 @@ void XReplaceable::testReplaceAll()
     xReplaceDescr->setSearchString(maReplaceString);
     xReplaceDescr->setReplaceString(maSearchString);
 
-    xReplaceable->replaceAll(uno::Reference< util::XSearchDescriptor >(xReplaceDescr, UNO_QUERY_THROW));
+    xReplaceable->replaceAll(
+        uno::Reference<util::XSearchDescriptor>(xReplaceDescr, UNO_QUERY_THROW));
 
     //check that it works
     xElement = xReplaceable->findFirst(xSearchDescr);
@@ -79,7 +83,6 @@ void XReplaceable::testReplaceAll()
     xElement = xReplaceable->findFirst(xSearchDescr);
     CPPUNIT_ASSERT(!xElement.is());
 }
-
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/test/source/util/xsearchable.cxx b/test/source/util/xsearchable.cxx
index b636377d8ed2..15b0cecde236 100644
--- a/test/source/util/xsearchable.cxx
+++ b/test/source/util/xsearchable.cxx
@@ -17,49 +17,46 @@
 using namespace css;
 using namespace css::uno;
 
-namespace apitest {
-
+namespace apitest
+{
 void XSearchable::testFindAll()
 {
-    uno::Reference< util::XSearchable > xSearchable(init(), UNO_QUERY_THROW);
-    uno::Reference< util::XSearchDescriptor> xSearchDescr = xSearchable->createSearchDescriptor();
+    uno::Reference<util::XSearchable> xSearchable(init(), UNO_QUERY_THROW);
+    uno::Reference<util::XSearchDescriptor> xSearchDescr = xSearchable->createSearchDescriptor();
     xSearchDescr->setSearchString(maSearchString);
 
-    uno::Reference< container::XIndexAccess > xIndex = xSearchable->findAll(xSearchDescr);
+    uno::Reference<container::XIndexAccess> xIndex = xSearchable->findAll(xSearchDescr);
     CPPUNIT_ASSERT(xIndex.is());
     CPPUNIT_ASSERT_EQUAL(mnCount, xIndex->getCount());
 }
 
 void XSearchable::testFindFirst()
 {
-    uno::Reference< util::XSearchable > xSearchable(init(), UNO_QUERY_THROW);
-    uno::Reference< util::XSearchDescriptor> xSearchDescr = xSearchable->createSearchDescriptor();
+    uno::Reference<util::XSearchable> xSearchable(init(), UNO_QUERY_THROW);
+    uno::Reference<util::XSearchDescriptor> xSearchDescr = xSearchable->createSearchDescriptor();
     xSearchDescr->setSearchString(maSearchString);
 
-    uno::Reference< uno::XInterface > xElement = xSearchable->findFirst(xSearchDescr);
+    uno::Reference<uno::XInterface> xElement = xSearchable->findFirst(xSearchDescr);
     CPPUNIT_ASSERT(xElement.is());
 }
 
 void XSearchable::testFindNext()
 {
-    uno::Reference< util::XSearchable > xSearchable(init(), UNO_QUERY_THROW);
-    uno::Reference< util::XSearchDescriptor> xSearchDescr = xSearchable->createSearchDescriptor();
+    uno::Reference<util::XSearchable> xSearchable(init(), UNO_QUERY_THROW);
+    uno::Reference<util::XSearchDescriptor> xSearchDescr = xSearchable->createSearchDescriptor();
     xSearchDescr->setSearchString(maSearchString);
 
-    uno::Reference< uno::XInterface > xElement = xSearchable->findFirst(xSearchDescr);
+    uno::Reference<uno::XInterface> xElement = xSearchable->findFirst(xSearchDescr);
     CPPUNIT_ASSERT(xElement.is());
 
     if (mnCount > 1)
     {
-        uno::Reference< uno::XInterface > xElement2 = xSearchable->findNext(xElement, xSearchDescr);
+        uno::Reference<uno::XInterface> xElement2 = xSearchable->findNext(xElement, xSearchDescr);
         CPPUNIT_ASSERT(xElement2.is());
     }
 }
 
-XSearchable::~XSearchable()
-{
-}
-
+XSearchable::~XSearchable() {}
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */


More information about the Libreoffice-commits mailing list