diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-08-06 10:55:58 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-08-13 08:16:03 +0200 |
commit | 3457da6abe0fd03efd19442e9790fbd1aa04c160 (patch) | |
tree | a7a2d5b51839b200e7cda79af863dce7a04d3a10 /desktop/qa | |
parent | 47196637a41ddfc9a8707771b1b9f482fd72c3b6 (diff) |
loplugin:stringstatic also look for local statics
Add some API to O*StringLiteral, to make it easier
to use in some places that were using O*String
Change-Id: I1fb93bd47ac2065c9220d509aad3f4320326d99e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100270
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'desktop/qa')
-rw-r--r-- | desktop/qa/desktop_lib/test_desktop_lib.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/desktop/qa/desktop_lib/test_desktop_lib.cxx b/desktop/qa/desktop_lib/test_desktop_lib.cxx index 68ce00bdfe84..8a1d1c927c20 100644 --- a/desktop/qa/desktop_lib/test_desktop_lib.cxx +++ b/desktop/qa/desktop_lib/test_desktop_lib.cxx @@ -2739,7 +2739,7 @@ void DesktopLOKTest::testComplexSelection() { // Start with a blank text file and add contents. LibLODocument_Impl* pDocument = loadDoc("blank_text.odt"); - static const OString aText("hello world"); + static const OStringLiteral aText("hello world"); // Certainly not complex. CPPUNIT_ASSERT_EQUAL(static_cast<int>(LOK_SELTYPE_NONE), pDocument->pClass->getSelectionType(pDocument)); @@ -2764,7 +2764,7 @@ void DesktopLOKTest::testComplexSelection() // Export as plain text, we should get only the text part "hello". char* pText = pDocument->pClass->getTextSelection(pDocument, "text/plain;charset=utf-8", nullptr); CPPUNIT_ASSERT(pText != nullptr); - CPPUNIT_ASSERT_EQUAL(aText, OString(pText)); + CPPUNIT_ASSERT_EQUAL(OString(aText), OString(pText)); free(pText); // Export as rtf, we should also get the image. @@ -2821,7 +2821,7 @@ void DesktopLOKTest::testCalcSaveAs() void DesktopLOKTest::testSpellcheckerMultiView() { - static const OUString aLangISO("en-US"); + static const OUStringLiteral aLangISO("en-US"); SvtSysLocaleOptions aSysLocaleOptions; aSysLocaleOptions.SetLocaleConfigString(aLangISO); aSysLocaleOptions.SetUILocaleConfigString(aLangISO); |