Kaydet (Commit) 1cc460e7 authored tarafından Miklos Vajna's avatar Miklos Vajna

CppunitTest_sw_uiwriter: loplugin:stringconstant

Change-Id: I818056164f9e41ac3b75a92ebfee06e0a1535b8a
üst a8860122
...@@ -2735,13 +2735,13 @@ void SwUiWriterTest::testTdf94804() ...@@ -2735,13 +2735,13 @@ void SwUiWriterTest::testTdf94804()
SwPaM* pCrsr = pDoc->GetEditShell()->GetCursor(); SwPaM* pCrsr = pDoc->GetEditShell()->GetCursor();
IDocumentMarkAccess* pIDMAccess(pDoc->getIDocumentMarkAccess()); IDocumentMarkAccess* pIDMAccess(pDoc->getIDocumentMarkAccess());
//make first bookmark, CROSSREF_HEADING, with *empty* name //make first bookmark, CROSSREF_HEADING, with *empty* name
sw::mark::IMark* pMark1(pIDMAccess->makeMark(*pCrsr, rtl::OUString(""), IDocumentMarkAccess::MarkType::CROSSREF_HEADING_BOOKMARK)); sw::mark::IMark* pMark1(pIDMAccess->makeMark(*pCrsr, "", IDocumentMarkAccess::MarkType::CROSSREF_HEADING_BOOKMARK));
//get the new(autogenerated) bookmark name //get the new(autogenerated) bookmark name
rtl::OUString bookmark1name = pMark1->GetName(); rtl::OUString bookmark1name = pMark1->GetName();
//match the bookmark name, it should be like "__RefHeading__**" //match the bookmark name, it should be like "__RefHeading__**"
CPPUNIT_ASSERT(bookmark1name.match("__RefHeading__")); CPPUNIT_ASSERT(bookmark1name.match("__RefHeading__"));
//make second bookmark, CROSSREF_NUMITEM, with *empty* name //make second bookmark, CROSSREF_NUMITEM, with *empty* name
sw::mark::IMark* pMark2(pIDMAccess->makeMark(*pCrsr, rtl::OUString(""), IDocumentMarkAccess::MarkType::CROSSREF_NUMITEM_BOOKMARK)); sw::mark::IMark* pMark2(pIDMAccess->makeMark(*pCrsr, "", IDocumentMarkAccess::MarkType::CROSSREF_NUMITEM_BOOKMARK));
//get the new(autogenerated) bookmark name //get the new(autogenerated) bookmark name
rtl::OUString bookmark2name = pMark2->GetName(); rtl::OUString bookmark2name = pMark2->GetName();
//match the bookmark name, it should be like "__RefNumPara__**" //match the bookmark name, it should be like "__RefNumPara__**"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment