diff options
Diffstat (limited to 'sw/qa/core/txtnode/txtnode.cxx')
-rw-r--r-- | sw/qa/core/txtnode/txtnode.cxx | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/sw/qa/core/txtnode/txtnode.cxx b/sw/qa/core/txtnode/txtnode.cxx index c23272285569..eb675c6e77b8 100644 --- a/sw/qa/core/txtnode/txtnode.cxx +++ b/sw/qa/core/txtnode/txtnode.cxx @@ -77,6 +77,18 @@ CPPUNIT_TEST_FIXTURE(SwCoreTxtnodeTest, testTextBoxCopyAnchor) CPPUNIT_ASSERT_EQUAL(aFlyAnchor2.nNode, aDrawAnchor2.nNode); } +CPPUNIT_TEST_FIXTURE(SwCoreTxtnodeTest, testTextBoxNodeSplit) +{ + load(DATA_DIRECTORY, "textbox-node-split.docx"); + SwXTextDocument* pTextDoc = dynamic_cast<SwXTextDocument*>(mxComponent.get()); + SwDocShell* pShell = pTextDoc->GetDocShell(); + SwWrtShell* pWrtShell = pShell->GetWrtShell(); + pWrtShell->SttEndDoc(/*bStart=*/false); + // Without the accompanying fix in place, this would have crashed in + // SwFlyAtContentFrame::Modify(). + pWrtShell->SplitNode(); +} + CPPUNIT_PLUGIN_IMPLEMENT(); /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |