diff options
Diffstat (limited to 'sd/qa/unit/import-tests.cxx')
-rw-r--r-- | sd/qa/unit/import-tests.cxx | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx index 7546689852a5..f9177c6493d3 100644 --- a/sd/qa/unit/import-tests.cxx +++ b/sd/qa/unit/import-tests.cxx @@ -171,6 +171,7 @@ public: void testSmartArtRotation(); void testTdf109223(); void testTdf109187(); + void testTdf108926(); bool checkPattern(sd::DrawDocShellRef const & rDocRef, int nShapeNumber, std::vector<sal_uInt8>& rExpected); void testPatternImport(); @@ -250,6 +251,7 @@ public: CPPUNIT_TEST(testSmartArtRotation); CPPUNIT_TEST(testTdf109223); CPPUNIT_TEST(testTdf109187); + CPPUNIT_TEST(testTdf108926); CPPUNIT_TEST_SUITE_END(); }; @@ -2431,6 +2433,23 @@ void SdImportTest::testTdf109187() xDocShRef->DoClose(); } +void SdImportTest::testTdf108926() +{ + sd::DrawDocShellRef xDocShRef = loadURL(m_directories.getURLFromSrc("sd/qa/unit/data/pptx/tdf108926.ppt"), PPT); + uno::Reference< presentation::XPresentationPage > xPage (getPage(0, xDocShRef), uno::UNO_QUERY_THROW); + uno::Reference< drawing::XDrawPage > xNotesPage (xPage->getNotesPage(), uno::UNO_QUERY_THROW); + CPPUNIT_ASSERT_EQUAL(static_cast<sal_Int32>(2), xNotesPage->getCount()); + + // Second object should be imported as an empty presentation shape + uno::Reference< beans::XPropertySet > xPresentationShape(xNotesPage->getByIndex(1), uno::UNO_QUERY); + CPPUNIT_ASSERT(xPresentationShape.is()); + bool bIsEmptyPresObject = false; + xPresentationShape->getPropertyValue( "IsEmptyPresentationObject" ) >>= bIsEmptyPresObject; + CPPUNIT_ASSERT(bIsEmptyPresObject); + + xDocShRef->DoClose(); +} + CPPUNIT_TEST_SUITE_REGISTRATION(SdImportTest); CPPUNIT_PLUGIN_IMPLEMENT(); |