diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2015-07-31 09:17:55 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2015-07-31 09:19:03 +0200 |
commit | 2c4e0aaa8d54877c55d3c4e397a7b869d8ff57cc (patch) | |
tree | 20847077ac87e23dd1d2c50ec66648206a2303cc | |
parent | ab9594038e1b3f6c4c260d0903376c2214ecc128 (diff) |
tdf#88986 testcase
Change-Id: I90d0c76c11e44ffe18be9fde4df06ccd0ac13da9
-rw-r--r-- | sw/qa/extras/uiwriter/uiwriter.cxx | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/sw/qa/extras/uiwriter/uiwriter.cxx b/sw/qa/extras/uiwriter/uiwriter.cxx index bf04bd037749..69da76acdc92 100644 --- a/sw/qa/extras/uiwriter/uiwriter.cxx +++ b/sw/qa/extras/uiwriter/uiwriter.cxx @@ -52,6 +52,8 @@ #include <editeng/wghtitem.hxx> #include "UndoManager.hxx" +#include <textsh.hxx> +#include <frmmgr.hxx> #include <com/sun/star/lang/Locale.hpp> #include <com/sun/star/lang/XMultiServiceFactory.hpp> @@ -145,6 +147,7 @@ public: void testDde(); void testTdf89954(); void testTdf89720(); + void testTdf88986(); CPPUNIT_TEST_SUITE(SwUiWriterTest); CPPUNIT_TEST(testReplaceForward); @@ -209,6 +212,7 @@ public: CPPUNIT_TEST(testDde); CPPUNIT_TEST(testTdf89954); CPPUNIT_TEST(testTdf89720); + CPPUNIT_TEST(testTdf88986); CPPUNIT_TEST_SUITE_END(); private: @@ -2146,6 +2150,22 @@ void SwUiWriterTest::testTdf89720() } } +void SwUiWriterTest::testTdf88986() +{ + // Create a text shell. + SwDoc* pDoc = createDoc(); + SwView* pView = pDoc->GetDocShell()->GetView(); + SwTextShell aShell(*pView); + + // Create the item set that is normally passed to the insert frame dialog. + SwWrtShell* pWrtShell = pDoc->GetDocShell()->GetWrtShell(); + SwFlyFrmAttrMgr aMgr(true, pWrtShell, FRMMGR_TYPE_TEXT); + SfxItemSet aSet = aShell.CreateInsertFrameItemSet(aMgr); + + // This was missing along with the gradient and other tables. + CPPUNIT_ASSERT(aSet.HasItem(SID_COLOR_TABLE)); +} + CPPUNIT_TEST_SUITE_REGISTRATION(SwUiWriterTest); CPPUNIT_PLUGIN_IMPLEMENT(); |