[Libreoffice-commits] .: svl/qa
August Sodora
augsod at kemper.freedesktop.org
Sat Nov 26 22:32:07 PST 2011
svl/qa/unit/test_lngmisc.cxx | 27 +++++++++++++--------------
1 file changed, 13 insertions(+), 14 deletions(-)
New commits:
commit 641d8928f89120637a4348092dc8400440770320
Author: August Sodora <augsod at gmail.com>
Date: Sun Nov 27 01:31:44 2011 -0500
String->OUString
diff --git a/svl/qa/unit/test_lngmisc.cxx b/svl/qa/unit/test_lngmisc.cxx
index d9c6ef3..561fde3 100644
--- a/svl/qa/unit/test_lngmisc.cxx
+++ b/svl/qa/unit/test_lngmisc.cxx
@@ -9,7 +9,6 @@
#include "svl/lngmisc.hxx"
#include <rtl/ustrbuf.hxx>
-#include <tools/string.hxx>
namespace
{
@@ -128,17 +127,17 @@ namespace
void LngMiscTest::testGetThesaurusReplaceText()
{
- const static String str1(RTL_CONSTASCII_USTRINGPARAM(""));
- const static String str2(RTL_CONSTASCII_USTRINGPARAM("asdf"));
- const static String str3(RTL_CONSTASCII_USTRINGPARAM("asdf (abc)"));
- const static String str4(RTL_CONSTASCII_USTRINGPARAM("asdf*"));
- const static String str5(RTL_CONSTASCII_USTRINGPARAM("asdf * "));
- const static String str6(RTL_CONSTASCII_USTRINGPARAM("asdf (abc) *"));
- const static String str7(RTL_CONSTASCII_USTRINGPARAM("asdf asdf * (abc)"));
- const static String str8(RTL_CONSTASCII_USTRINGPARAM(" * (abc) asdf *"));
-
- String r = linguistic::GetThesaurusReplaceText(str1);
- CPPUNIT_ASSERT(!r.Len());
+ const static ::rtl::OUString str1(RTL_CONSTASCII_USTRINGPARAM(""));
+ const static ::rtl::OUString str2(RTL_CONSTASCII_USTRINGPARAM("asdf"));
+ const static ::rtl::OUString str3(RTL_CONSTASCII_USTRINGPARAM("asdf (abc)"));
+ const static ::rtl::OUString str4(RTL_CONSTASCII_USTRINGPARAM("asdf*"));
+ const static ::rtl::OUString str5(RTL_CONSTASCII_USTRINGPARAM("asdf * "));
+ const static ::rtl::OUString str6(RTL_CONSTASCII_USTRINGPARAM("asdf (abc) *"));
+ const static ::rtl::OUString str7(RTL_CONSTASCII_USTRINGPARAM("asdf asdf * (abc)"));
+ const static ::rtl::OUString str8(RTL_CONSTASCII_USTRINGPARAM(" * (abc) asdf *"));
+
+ ::rtl::OUString r = linguistic::GetThesaurusReplaceText(str1);
+ CPPUNIT_ASSERT(r.isEmpty());
r = linguistic::GetThesaurusReplaceText(str2);
CPPUNIT_ASSERT(r == str2);
@@ -156,10 +155,10 @@ namespace
CPPUNIT_ASSERT(r == str2);
r = linguistic::GetThesaurusReplaceText(str7);
- CPPUNIT_ASSERT(r == String::CreateFromAscii("asdf asdf"));
+ CPPUNIT_ASSERT(r == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("asdf asdf")));
r = linguistic::GetThesaurusReplaceText(str8);
- CPPUNIT_ASSERT(!r.Len());
+ CPPUNIT_ASSERT(r.isEmpty());
}
CPPUNIT_TEST_SUITE_REGISTRATION(LngMiscTest);
More information about the Libreoffice-commits
mailing list