[Libreoffice-commits] core.git: sd/qa
Charu Tyagi
charu.tyagi at ericsson.com
Thu May 14 06:29:26 PDT 2015
sd/qa/unit/data/fdo90607.pptx |binary
sd/qa/unit/export-tests.cxx | 26 ++++++++++++++++++++++++++
2 files changed, 26 insertions(+)
New commits:
commit 58f43ab810311d8b7238317f4cec5346eebdbb17
Author: Charu Tyagi <charu.tyagi at ericsson.com>
Date: Tue Apr 21 15:04:34 2015 +0530
tdf#90607-Test Case for the patch
Change-Id: Ifcd75cc47baf9da7b3480a4a1e51853aa66c3f1c
Reviewed-on: https://gerrit.libreoffice.org/15458
Tested-by: Jenkins <ci at libreoffice.org>
Tested-by: Caolán McNamara <caolanm at redhat.com>
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/sd/qa/unit/data/fdo90607.pptx b/sd/qa/unit/data/fdo90607.pptx
new file mode 100644
index 0000000..0c01aa8
Binary files /dev/null and b/sd/qa/unit/data/fdo90607.pptx differ
diff --git a/sd/qa/unit/export-tests.cxx b/sd/qa/unit/export-tests.cxx
index 036e179..3151afb 100644
--- a/sd/qa/unit/export-tests.cxx
+++ b/sd/qa/unit/export-tests.cxx
@@ -103,11 +103,13 @@ public:
void testBulletMarginAndIndentation();
void testParaMarginAndindentation();
+ void testFdo90607();
#if !defined WNT
void testBnc822341();
#endif
CPPUNIT_TEST_SUITE(SdExportTest);
+ CPPUNIT_TEST(testFdo90607);
CPPUNIT_TEST(testN821567);
CPPUNIT_TEST(testBnc870233_1);
CPPUNIT_TEST(testBnc870233_2);
@@ -527,6 +529,30 @@ void SdExportTest::testBnc822347_EmptyBullet()
xDocShRef->DoClose();
}
+//Bullets not having any text following them are not getting exported to pptx correctly.
+void SdExportTest::testFdo90607()
+{
+ sd::DrawDocShellRef xDocShRef = loadURL(getURLFromSrc("/sd/qa/unit/data/fdo90607.pptx"), PPTX);
+ xDocShRef = saveAndReload(xDocShRef, PPTX);
+
+ uno::Reference< drawing::XDrawPagesSupplier > xDoc(
+ xDocShRef->GetDoc()->getUnoModel(), uno::UNO_QUERY_THROW );
+
+ uno::Reference< drawing::XDrawPage > xPage(
+ xDoc->getDrawPages()->getByIndex(0), uno::UNO_QUERY_THROW );
+ SdDrawDocument *pDoc = xDocShRef->GetDoc();
+ CPPUNIT_ASSERT_MESSAGE( "no document", pDoc != NULL );
+
+ const SdrPage *pPage = pDoc->GetPage(1);
+ CPPUNIT_ASSERT_MESSAGE( "no page", pPage != NULL );
+ SdrTextObj *pTxtObj = dynamic_cast<SdrTextObj *>( pPage->GetObj(1) );
+ CPPUNIT_ASSERT_MESSAGE( "no text object", pTxtObj != NULL);
+ OutlinerParaObject* pOutlinerParagraphObject = pTxtObj->GetOutlinerParaObject();
+ const sal_Int16 nDepth = pOutlinerParagraphObject->GetDepth(0);
+ CPPUNIT_ASSERT_MESSAGE("not equal", nDepth != -1);
+ xDocShRef->DoClose();
+}
+
void SdExportTest::testFdo83751()
{
::sd::DrawDocShellRef xDocShRef = loadURL(getURLFromSrc("/sd/qa/unit/data/pptx/fdo83751.pptx"), PPTX);
More information about the Libreoffice-commits
mailing list