summaryrefslogtreecommitdiff
path: root/sw/qa/extras/uiwriter/uiwriter.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sw/qa/extras/uiwriter/uiwriter.cxx')
-rw-r--r--sw/qa/extras/uiwriter/uiwriter.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/sw/qa/extras/uiwriter/uiwriter.cxx b/sw/qa/extras/uiwriter/uiwriter.cxx
index 2acfc17b7082..f1bb78af34cb 100644
--- a/sw/qa/extras/uiwriter/uiwriter.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter.cxx
@@ -7652,11 +7652,18 @@ void SwUiWriterTest::testRedlineAutoCorrect()
nIndex = pWrtShell->GetCursor()->GetNode().GetIndex();
CPPUNIT_ASSERT_EQUAL(sReplaced, static_cast<SwTextNode*>(pDoc->GetNodes()[nIndex])->GetText());
+ // Including capitalization
+ pWrtShell->Insert("end. word");
+ pWrtShell->AutoCorrect(corr, ' ');
+ sReplaced = "tset test end. Word ";
+ nIndex = pWrtShell->GetCursor()->GetNode().GetIndex();
+ CPPUNIT_ASSERT_EQUAL(sReplaced, static_cast<SwTextNode*>(pDoc->GetNodes()[nIndex])->GetText());
+
// tracked deletions after the correction point doesn't affect autocorrect
dispatchCommand(mxComponent, ".uno:GoToStartOfDoc", {});
pWrtShell->Insert("a");
pWrtShell->AutoCorrect(corr, ' ');
- sReplaced = "A tset test ";
+ sReplaced = "A tset test end. Word ";
nIndex = pWrtShell->GetCursor()->GetNode().GetIndex();
CPPUNIT_ASSERT_EQUAL(sReplaced, static_cast<SwTextNode*>(pDoc->GetNodes()[nIndex])->GetText());
}