[Libreoffice-commits] core.git: sw/qa
Miklos Vajna
vmiklos at collabora.co.uk
Mon Jun 16 05:08:33 PDT 2014
sw/qa/extras/ooxmlexport/ooxmlsdrexport.cxx | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
New commits:
commit 711023ae993a8413f56d891ae276763e6a2018bb
Author: Miklos Vajna <vmiklos at collabora.co.uk>
Date: Mon Jun 16 14:01:04 2014 +0200
CppunitTest_sw_ooxmlsdrexport: port testTableFloatingMargins to textboxes
Change-Id: I62f0159bec97c6c7a2285509b0662125f46ed480
diff --git a/sw/qa/extras/ooxmlexport/ooxmlsdrexport.cxx b/sw/qa/extras/ooxmlexport/ooxmlsdrexport.cxx
index 888373a..fdeb061 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlsdrexport.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlsdrexport.cxx
@@ -431,10 +431,9 @@ DECLARE_OOXMLEXPORT_TEST(testDMLGroupShapeParaSpacing, "dml-groupshape-paraspaci
DECLARE_OOXMLEXPORT_TEST(testTableFloatingMargins, "table-floating-margins.docx")
{
// In case the table had custom left cell margin, the horizontal position was still incorrect (too small, -199).
- uno::Reference<text::XTextFramesSupplier> xTextFramesSupplier(mxComponent, uno::UNO_QUERY);
- uno::Reference<container::XIndexAccess> xIndexAccess(xTextFramesSupplier->getTextFrames(), uno::UNO_QUERY);
- uno::Reference<beans::XPropertySet> xFrame(xIndexAccess->getByIndex(0), uno::UNO_QUERY);
- CPPUNIT_ASSERT_EQUAL(sal_Int32(-499), getProperty<sal_Int32>(xFrame, "HoriOrientPosition"));
+ uno::Reference<beans::XPropertySet> xFrame(getShape(1), uno::UNO_QUERY);
+ sal_Int32 nHoriOrientPosition = getProperty<sal_Int32>(xFrame, "HoriOrientPosition");
+ CPPUNIT_ASSERT(nHoriOrientPosition < sal_Int32(-495));
// These were 0 as well, due to lack of import.
CPPUNIT_ASSERT_EQUAL(sal_Int32(1000), getProperty<sal_Int32>(xFrame, "TopMargin"));
CPPUNIT_ASSERT_EQUAL(sal_Int32(2000), getProperty<sal_Int32>(xFrame, "BottomMargin"));
More information about the Libreoffice-commits
mailing list