[Libreoffice-commits] .: i18npool/qa

2012-11-19 Thread Libreoffice Gerrit user
 i18npool/qa/cppunit/test_textsearch.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 7228c24e38363ed4684936f69eb49a7905b5a16b
Author: Zolnai Tamás zolnaitamas20...@gmail.com
Date:   Mon Nov 19 15:58:52 2012 +0100

Stop a memory leak in text_textsearch.cxx

Change-Id: I4dad05dbbe668ac7d7058cb43989f6a9f8e488a6
Reviewed-on: https://gerrit.libreoffice.org/1118
Reviewed-by: Luboš Luňák l.lu...@suse.cz
Tested-by: Luboš Luňák l.lu...@suse.cz

diff --git a/i18npool/qa/cppunit/test_textsearch.cxx 
b/i18npool/qa/cppunit/test_textsearch.cxx
index 682a607..c26550b 100644
--- a/i18npool/qa/cppunit/test_textsearch.cxx
+++ b/i18npool/qa/cppunit/test_textsearch.cxx
@@ -92,6 +92,7 @@ void TestTextSearch::testICU()
 CPPUNIT_ASSERT( nErr == U_ZERO_ERROR );
 CPPUNIT_ASSERT( pRegexMatcher-end( nErr ) == 1 );
 CPPUNIT_ASSERT( nErr == U_ZERO_ERROR );
+delete pRegexMatcher;
 }
 
 void TestTextSearch::testSearches()
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa i18npool/source

2012-09-19 Thread Libreoffice Gerrit user
 i18npool/qa/cppunit/test_breakiterator.cxx |   28 +++-
 i18npool/source/breakiterator/data/README  |8 +---
 2 files changed, 24 insertions(+), 12 deletions(-)

New commits:
commit 558476135865d9ae7b8801a82c177fd1098386ff
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Sep 19 09:10:56 2012 +0100

Related: #112623# add regression test for japanese word break rules

Change-Id: I05baf163cc00d3770b9a8b25b099ffcbd9623a2f

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index aa4e943..a6bc2cd 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -898,14 +898,32 @@ void TestBreakIterator::testJapanese()
 lang::Locale aLocale;
 aLocale.Language = OUString(ja);
 aLocale.Country = OUString(JP);
+i18n::Boundary aBounds;
 
-const sal_Unicode JAPANESE[] = { 0x30B7, 0x30E3, 0x30C3, 0x30C8, 0x30C0, 
0x30A6, 0x30F3 };
+{
+const sal_Unicode JAPANESE[] = { 0x30B7, 0x30E3, 0x30C3, 0x30C8, 
0x30C0, 0x30A6, 0x30F3 };
 
-rtl::OUString aTest(JAPANESE, SAL_N_ELEMENTS(JAPANESE));
-i18n::Boundary aBounds = m_xBreak-getWordBoundary(aTest, 5, aLocale,
-i18n::WordType::DICTIONARY_WORD, true);
+rtl::OUString aTest(JAPANESE, SAL_N_ELEMENTS(JAPANESE));
+aBounds = m_xBreak-getWordBoundary(aTest, 5, aLocale,
+i18n::WordType::DICTIONARY_WORD, true);
 
-CPPUNIT_ASSERT(aBounds.startPos == 0  aBounds.endPos == 7);
+CPPUNIT_ASSERT(aBounds.startPos == 0  aBounds.endPos == 7);
+}
+
+{
+const sal_Unicode JAPANESE[] = { 0x9EBB, 0x306E, 0x8449, 0x9EBB, 
0x306E, 0x8449 };
+
+rtl::OUString aTest(JAPANESE, SAL_N_ELEMENTS(JAPANESE));
+aBounds = m_xBreak-getWordBoundary(aTest, 1, aLocale,
+i18n::WordType::DICTIONARY_WORD, true);
+
+CPPUNIT_ASSERT(aBounds.startPos == 0  aBounds.endPos == 3);
+
+aBounds = m_xBreak-getWordBoundary(aTest, 5, aLocale,
+i18n::WordType::DICTIONARY_WORD, true);
+
+CPPUNIT_ASSERT(aBounds.startPos == 3  aBounds.endPos == 6);
+}
 }
 
 void TestBreakIterator::setUp()
diff --git a/i18npool/source/breakiterator/data/README 
b/i18npool/source/breakiterator/data/README
index 2b4e7cd..f1a05c9 100644
--- a/i18npool/source/breakiterator/data/README
+++ b/i18npool/source/breakiterator/data/README
@@ -495,13 +495,6 @@ Date:   Fri May 28 15:33:02 2004 +
 2004/04/30 11:25:47 er 1.13.22.2: RESYNC: (1.13-1.14); FILE MERGED
 2004/04/13 11:55:32 er 1.13.22.1: #i27711# Hungarian breakiterator
 
-commit 170eb11a6d894ace40b2e4708264b0142ac4e603
-Author: Oliver Bolte o...@openoffice.org
-Date:   Wed Mar 17 08:02:36 2004 +
-
-INTEGRATION: CWS i18n11 (1.1.124); FILE MERGED
-2004/01/06 19:36:16 khong 1.1.124.1: #112623# update Japanese word 
breakiterator dictionary
-
 commit f5bc5f04e4de8fa502d498a99f4ef6a340d796c0
 Author: Oliver Bolte o...@openoffice.org
 Date:   Wed Mar 17 08:02:14 2004 +
@@ -529,6 +522,7 @@ Date:   Mon Mar 8 16:17:05 2004 +
 
 done, regression tests added:
 
+#112623# update Japanese word breakiterator dictionary
 #i50172# add cell breakiterator rule for Tamil
 #i80412# indic cursoring
 #i107843# em-dash/en-dash breakiterator fix for spell checking
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa i18npool/source

2012-09-07 Thread Libreoffice Gerrit user
 i18npool/qa/cppunit/test_breakiterator.cxx |   23 ++-
 i18npool/source/breakiterator/data/README  |7 +--
 2 files changed, 23 insertions(+), 7 deletions(-)

New commits:
commit 08de755c078b96922ea7693553e4f4b5e7bab740
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Sep 7 09:17:26 2012 +0100

Related: #i107843# add regression test for em-dash/en-dash spell checking

Change-Id: I8d9aad9ac648aefdd1f31e09fe2ea84a698c0013

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index 2073a9d..f8f4d71 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -530,7 +530,7 @@ void TestBreakIterator::testWordBoundaries()
 }
 }
 
-//See https://issues.apache.org/ooo/show_bug.cgi?id=113785
+//See https://issues.apache.org/ooo/show_bug.cgi?id=107843
 {
 aLocale.Language = rtl::OUString(en);
 aLocale.Country = rtl::OUString(US);
@@ -547,6 +547,27 @@ void TestBreakIterator::testWordBoundaries()
 aBounds = m_xBreak-getWordBoundary(aTest, 7, aLocale, 
i18n::WordType::DICTIONARY_WORD, false);
 CPPUNIT_ASSERT(aBounds.startPos == 6  aBounds.endPos == 9);
 }
+
+//See https://issues.apache.org/ooo/show_bug.cgi?id=113785
+{
+aLocale.Language = rtl::OUString(en);
+aLocale.Country = rtl::OUString(US);
+
+const sal_Unicode TEST[] =
+{
+'a', 0x2013, 'b', 0x2014, 'c'
+};
+rtl::OUString aTest(TEST, SAL_N_ELEMENTS(TEST));
+
+aBounds = m_xBreak-getWordBoundary(aTest, 0, aLocale, 
i18n::WordType::DICTIONARY_WORD, true);
+CPPUNIT_ASSERT(aBounds.startPos == 0  aBounds.endPos == 1);
+
+aBounds = m_xBreak-nextWord(aTest, 0, aLocale, 
i18n::WordType::DICTIONARY_WORD);
+CPPUNIT_ASSERT(aBounds.startPos == 2  aBounds.endPos == 3);
+
+aBounds = m_xBreak-nextWord(aTest, aBounds.endPos, aLocale, 
i18n::WordType::DICTIONARY_WORD);
+CPPUNIT_ASSERT(aBounds.startPos == 4  aBounds.endPos == 5);
+}
 }
 
 //See http://qa.openoffice.org/issues/show_bug.cgi?id=52
diff --git a/i18npool/source/breakiterator/data/README 
b/i18npool/source/breakiterator/data/README
index 95f6b00..22136e7 100644
--- a/i18npool/source/breakiterator/data/README
+++ b/i18npool/source/breakiterator/data/README
@@ -16,12 +16,6 @@ latest versions.
 
 to-review, later are ok:
 
-commit ffdc043d7272d2e0a664f530bbc112f952acadab
-Author: Thomas Lange [tl] t...@openoffice.org
-Date:   Mon Mar 15 09:22:49 2010 +0100
-
-cws sw321bf01: #i107843# em-dash/en-dash breakiterator fix for spell 
checking
-
 commit e1ad946ef5db3f7c0a540207d0f0fd85799e3b66
 Author: Release Engineers rel...@openoffice.org
 Date:   Thu Aug 6 18:13:57 2009 +
@@ -555,6 +549,7 @@ Date:   Mon Mar 8 16:17:05 2004 +
 
 done, regression tests added:
 
+#i107843# em-dash/en-dash breakiterator fix for spell checking
 #i103552# Japanese word for 'shutdown' added to ja.dic
 #i113785# ligatures for spell checking will no longer break words
 An opening quote should not be counted as a word by word count tool 
(regression test in in writer)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa i18npool/source

2012-09-07 Thread Libreoffice Gerrit user
 i18npool/qa/cppunit/test_breakiterator.cxx |   21 -
 i18npool/source/breakiterator/data/README  |   14 +-
 2 files changed, 21 insertions(+), 14 deletions(-)

New commits:
commit 9b69085c5da49aa64c531b27d078a3f4a353103c
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Sep 7 12:20:24 2012 +0100

Related: #i80412# add regression test for Indic language cursoring

Change-Id: Ia1cc6ade8d2122abf5469ec521b2883961121a04

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index f8f4d71..c00b086 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -570,8 +570,9 @@ void TestBreakIterator::testWordBoundaries()
 }
 }
 
-//See http://qa.openoffice.org/issues/show_bug.cgi?id=52
 //See https://bugs.freedesktop.org/show_bug.cgi?id=40292
+//See https://issues.apache.org/ooo/show_bug.cgi?id=80412
+//See https://issues.apache.org/ooo/show_bug.cgi?id=52
 void TestBreakIterator::testGraphemeIteration()
 {
 lang::Locale aLocale;
@@ -681,6 +682,24 @@ void TestBreakIterator::testGraphemeIteration()
 
 CPPUNIT_ASSERT_MESSAGE(Should be considered 1 grapheme, 
nGraphemeCount == 1);
 }
+
+aLocale.Language = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(hi));
+aLocale.Country = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(IN));
+
+{
+const sal_Unicode SHA_VOWELSIGNII[] = { 0x936, 0x940 };
+rtl::OUString aTest(SHA_VOWELSIGNII, SAL_N_ELEMENTS(SHA_VOWELSIGNII));
+
+sal_Int32 nDone=0;
+sal_Int32 nPos = 0;
+
+nPos = m_xBreak-nextCharacters(aTest, 0, aLocale,
+i18n::CharacterIteratorMode::SKIPCELL, 1, nDone);
+CPPUNIT_ASSERT_MESSAGE(Should skip full grapheme, nPos == 
SAL_N_ELEMENTS(SHA_VOWELSIGNII));
+nPos = m_xBreak-previousCharacters(aTest, 
SAL_N_ELEMENTS(SHA_VOWELSIGNII), aLocale,
+i18n::CharacterIteratorMode::SKIPCELL, 1, nDone);
+CPPUNIT_ASSERT_MESSAGE(Should skip full grapheme, nPos == 0);
+}
 }
 
 //A test to ensure that certain ranges and codepoints that are categorized as
diff --git a/i18npool/source/breakiterator/data/README 
b/i18npool/source/breakiterator/data/README
index 22136e7..a4dc9e8 100644
--- a/i18npool/source/breakiterator/data/README
+++ b/i18npool/source/breakiterator/data/README
@@ -23,19 +23,6 @@ Date:   Thu Aug 6 18:13:57 2009 +
 CWS-TOOLING: integrate CWS tl73
 2009-07-31 15:29:33 +0200 tl  r274535 : #i64400# dash/hyphen should not 
break words
 
-commit 4e1fd2fa161708049f1c3b6039659d0bf4f4539e
-Author: Jens-Heiner Rechtien h...@openoffice.org
-Date:   Tue Jan 6 12:54:16 2009 +
-
-2008-12-03 16:14:17 +0100 erack  r264797 : #i93694# update script+language 
- unicode digit mapping; patch from hdu
-2008-11-25 02:01:18 +0100 erack  r264270 : #i83349# apply remaining parts 
of the patch, now that we use ICU 4.0; contributed by kstribley
-
-commit 16b796fcce6430448535e3692f624cb469380442
-Author: Release Engineers rel...@openoffice.org
-Date:   Thu Oct 2 13:51:29 2008 +
-
-#i80412#
-
 commit 9964a76ef58786bba47d409970512d7ded6c8889
 Author: Rüdiger Timm r...@openoffice.org
 Date:   Wed Jul 2 07:53:05 2008 +
@@ -549,6 +536,7 @@ Date:   Mon Mar 8 16:17:05 2004 +
 
 done, regression tests added:
 
+#i80412# indic cursoring
 #i107843# em-dash/en-dash breakiterator fix for spell checking
 #i103552# Japanese word for 'shutdown' added to ja.dic
 #i113785# ligatures for spell checking will no longer break words
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa i18npool/source

2012-09-07 Thread Libreoffice Gerrit user
 i18npool/qa/cppunit/test_breakiterator.cxx |   16 
 i18npool/source/breakiterator/data/README  |8 +---
 2 files changed, 17 insertions(+), 7 deletions(-)

New commits:
commit 346cf4ee5d2f82b59900de1f71160c0d90ffab41
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Sep 7 12:39:02 2012 +0100

Related: #i50172# add regression test for Tamil cursoring

Change-Id: I8f6c3814aa3630f5f640f611fb51ce72641715c6

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index c00b086..aa4e943 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -573,6 +573,7 @@ void TestBreakIterator::testWordBoundaries()
 //See https://bugs.freedesktop.org/show_bug.cgi?id=40292
 //See https://issues.apache.org/ooo/show_bug.cgi?id=80412
 //See https://issues.apache.org/ooo/show_bug.cgi?id=52
+//See https://issues.apache.org/ooo/show_bug.cgi?id=50172
 void TestBreakIterator::testGraphemeIteration()
 {
 lang::Locale aLocale;
@@ -640,6 +641,21 @@ void TestBreakIterator::testGraphemeIteration()
 }
 
 {
+const sal_Unicode KA_VOWELSIGNU[] = { 0x0B95, 0x0BC1 };
+rtl::OUString aTest(KA_VOWELSIGNU, SAL_N_ELEMENTS(KA_VOWELSIGNU));
+
+sal_Int32 nDone=0;
+sal_Int32 nPos = 0;
+
+nPos = m_xBreak-nextCharacters(aTest, 0, aLocale,
+i18n::CharacterIteratorMode::SKIPCELL, 1, nDone);
+CPPUNIT_ASSERT_MESSAGE(Should skip full grapheme, nPos == 
SAL_N_ELEMENTS(KA_VOWELSIGNU));
+nPos = m_xBreak-previousCharacters(aTest, 
SAL_N_ELEMENTS(KA_VOWELSIGNU), aLocale,
+i18n::CharacterIteratorMode::SKIPCELL, 1, nDone);
+CPPUNIT_ASSERT_MESSAGE(Should skip full grapheme, nPos == 0);
+}
+
+{
 const sal_Unicode 
CA_VOWELSIGNI_TA_VIRAMA_TA_VOWELSIGNI_RA_VOWELSIGNAI[] =
 { 0x0B9A, 0x0BBF, 0x0BA4, 0x0BCD, 0x0BA4, 0x0BBF, 0x0BB0, 0x0BC8 };
 rtl::OUString 
aTest(CA_VOWELSIGNI_TA_VIRAMA_TA_VOWELSIGNI_RA_VOWELSIGNAI,
diff --git a/i18npool/source/breakiterator/data/README 
b/i18npool/source/breakiterator/data/README
index a4dc9e8..2b4e7cd 100644
--- a/i18npool/source/breakiterator/data/README
+++ b/i18npool/source/breakiterator/data/README
@@ -378,13 +378,6 @@ Date:   Mon Oct 17 14:43:17 2005 +
 INTEGRATION: CWS i18n20 (1.1.2); FILE ADDED
 2005/09/22 23:47:49 khong 1.1.2.1: #i51661# add quotation mark as middle 
letter for Hebrew in word breakiterator rule.
 
-commit 268567aa88a991e055c41d9115bccce951f7e308
-Author: Rüdiger Timm r...@openoffice.org
-Date:   Mon Oct 17 14:42:47 2005 +
-
-INTEGRATION: CWS i18n20 (1.1.2); FILE ADDED
-2005/08/26 23:33:38 khong 1.1.2.1: #i50172# add cell breakiterator rule 
for Tamil
-
 commit a428a8927006a10ccfe7182e6fe5a8b677281eca
 Author: Rüdiger Timm r...@openoffice.org
 Date:   Mon Oct 17 14:42:30 2005 +
@@ -536,6 +529,7 @@ Date:   Mon Mar 8 16:17:05 2004 +
 
 done, regression tests added:
 
+#i50172# add cell breakiterator rule for Tamil
 #i80412# indic cursoring
 #i107843# em-dash/en-dash breakiterator fix for spell checking
 #i103552# Japanese word for 'shutdown' added to ja.dic
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa

2012-08-31 Thread Libreoffice Gerrit user
 i18npool/qa/cppunit/test_languagetag.cxx |   23 ---
 1 file changed, 23 deletions(-)

New commits:
commit b75664ce3ceb0673f61cb5320b1e8b44f1b805d1
Author: Eike Rathke er...@redhat.com
Date:   Fri Aug 31 18:42:58 2012 +0200

testInit() with overrideDataPath() is obsolete now

Change-Id: Ic59da3ff8f86af3e74cc526b2f4c490bd144686d

diff --git a/i18npool/qa/cppunit/test_languagetag.cxx 
b/i18npool/qa/cppunit/test_languagetag.cxx
index 4569e81..3bb7163 100644
--- a/i18npool/qa/cppunit/test_languagetag.cxx
+++ b/i18npool/qa/cppunit/test_languagetag.cxx
@@ -40,36 +40,13 @@ public:
 TestLanguageTag() {}
 virtual ~TestLanguageTag() {}
 
-void testInit();
 void testAllTags();
 
 CPPUNIT_TEST_SUITE(TestLanguageTag);
-CPPUNIT_TEST(testInit);
 CPPUNIT_TEST(testAllTags);
 CPPUNIT_TEST_SUITE_END();
 };
 
-void TestLanguageTag::testInit()
-{
-#if USE_LIBLANGTAG  !defined(SYSTEM_LIBLANGTAG)
-// file:///$SRCDIR/solver/$INPATH/share/liblangtag
-// file:///$OUTDIR/share/liblangtag
-OUStringBuffer aBuf(128);
-const char* pEnv = getenv(OUTDIR);
-CPPUNIT_ASSERT_MESSAGE(No $OUTDIR, pEnv);
-aBuf.append( file:///).append( OStringToOUString( pEnv, 
RTL_TEXTENCODING_UTF8)).append( /share/liblangtag);
-OUString aURL( aBuf.makeStringAndClear());
-OUString aData( aURL);
-aData += /language-subtag-registry.xml;
-osl::DirectoryItem aDirItem;
-CPPUNIT_ASSERT_MESSAGE(liblangtag data not found,
-osl::DirectoryItem::get( aData, aDirItem) == 
osl::DirectoryItem::E_None);
-OUString aPath;
-CPPUNIT_ASSERT( osl::FileBase::getSystemPathFromFileURL( aURL, aPath) == 
osl::FileBase::E_None);
-LanguageTag::overrideDataPath( aPath);
-#endif
-}
-
 void TestLanguageTag::testAllTags()
 {
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa

2012-07-27 Thread Caolán McNamara
 i18npool/qa/cppunit/test_breakiterator.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit fb66fd63d4a1ea26d0191d3b39cb7e25abf2e714
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Jul 27 16:09:45 2012 +0100

stray fprintf

Change-Id: Icd10968e886be1d534e8037db6225e83712384ee

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index 89b947f..38a1865 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -152,7 +152,6 @@ void TestBreakIterator::testLineBreaking()
 //Here we want the line break to move the whole lot to the next 
line
 i18n::LineBreakResults aResult = m_xBreak-getLineBreak(aTest, 
aTest.getLength()-2, aLocale, 0,
 aHyphOptions, aUserOptions);
-fprintf(stderr, suggestion was %d\n, aResult.breakIndex);
 CPPUNIT_ASSERT_MESSAGE(Expected a break at the start of the line, 
not at ], aResult.breakIndex == 0);
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa

2012-07-24 Thread Jan Holesovsky
 i18npool/qa/cppunit/test_breakiterator.cxx |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 43b75d8af0efb359887c0ae1b2655c617d42f9a3
Author: Jan Holesovsky ke...@suse.cz
Date:   Tue Jul 24 15:28:23 2012 +0200

Disable testWordBoundaries test with old icu.

Change-Id: I8d75eeb2eee43e1338a6f54c4b8ed633631bac0d

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index f983686..b944540 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -68,7 +68,9 @@ public:
 
 CPPUNIT_TEST_SUITE(TestBreakIterator);
 CPPUNIT_TEST(testLineBreaking);
+#if (U_ICU_VERSION_MAJOR_NUM  4)
 CPPUNIT_TEST(testWordBoundaries);
+#endif
 CPPUNIT_TEST(testGraphemeIteration);
 CPPUNIT_TEST(testWeak);
 CPPUNIT_TEST(testAsian);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa i18npool/source

2012-07-13 Thread Caolán McNamara
 i18npool/qa/cppunit/test_breakiterator.cxx  |   24 
 i18npool/source/breakiterator/breakiterator_unicode.cxx |2 -
 2 files changed, 25 insertions(+), 1 deletion(-)

New commits:
commit 8ad1d4443e67784a8c0d3c1a3a72f089cb0cd3ec
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Jul 13 09:49:02 2012 +0100

Resolves: fdo#52020 ICU breakiterator not used for Khmer

Change-Id: I4c99129cabe70f17aa223cf8ec0ae1529188b6b7

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index c191bbc..68dc1ef 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -59,6 +59,7 @@ public:
 #if TODO
 void testNorthernThai();
 #endif
+void testKhmer();
 
 CPPUNIT_TEST_SUITE(TestBreakIterator);
 CPPUNIT_TEST(testLineBreaking);
@@ -69,6 +70,7 @@ public:
 #if TODO
 CPPUNIT_TEST(testNorthernThai);
 #endif
+CPPUNIT_TEST(testKhmer);
 CPPUNIT_TEST_SUITE_END();
 private:
 uno::Referencei18n::XBreakIterator m_xBreak;
@@ -341,6 +343,28 @@ void TestBreakIterator::testNorthernThai()
 }
 #endif
 
+//A test to ensure that our khmer word boundary detection is useful
+//https://bugs.freedesktop.org/show_bug.cgi?id=52020
+void TestBreakIterator::testKhmer()
+{
+lang::Locale aLocale;
+aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(km));
+aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(KH));
+
+const sal_Unicode KHMER1[] = { 0x17B2, 0x17D2, 0x1799, 0x1782, 0x17C1 };
+
+::rtl::OUString aTest(KHMER1, SAL_N_ELEMENTS(KHMER1));
+i18n::Boundary aBounds = m_xBreak-getWordBoundary(aTest, 0, aLocale,
+i18n::WordType::DICTIONARY_WORD, true);
+
+CPPUNIT_ASSERT(aBounds.startPos == 0  aBounds.endPos == 3);
+
+aBounds = m_xBreak-getWordBoundary(aTest, aBounds.endPos, aLocale,
+i18n::WordType::DICTIONARY_WORD, true);
+
+CPPUNIT_ASSERT(aBounds.startPos == 3  aBounds.endPos == 5);
+}
+
 void TestBreakIterator::setUp()
 {
 BootstrapFixtureBase::setUp();
diff --git a/i18npool/source/breakiterator/breakiterator_unicode.cxx 
b/i18npool/source/breakiterator/breakiterator_unicode.cxx
index 2e32656..0669c01 100644
--- a/i18npool/source/breakiterator/breakiterator_unicode.cxx
+++ b/i18npool/source/breakiterator/breakiterator_unicode.cxx
@@ -133,7 +133,7 @@ void SAL_CALL 
BreakIterator_Unicode::loadICUBreakIterator(const com::sun::star::
 rbi = new OOoRuleBasedBreakIterator(udata_open(OpenOffice, 
brk,
 OUStringToOString(breakRules[breakType], 
RTL_TEXTENCODING_ASCII_US).getStr(), status), status);
 }
-else if ( rLocale.Language != th ) //use icu's breakiterator for 
Thai
+else if (rLocale.Language != th  rLocale.Language != km) 
//use icu's breakiterator for Thai and Khmer
 {
 status = U_ZERO_ERROR;
 OStringBuffer aUDName(64);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa

2012-07-13 Thread Caolán McNamara
 i18npool/qa/cppunit/test_breakiterator.cxx |   11 +++
 1 file changed, 11 insertions(+)

New commits:
commit b32fcb79af8fdf905c8e09f987f7754a43079901
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Jul 13 11:10:45 2012 +0100

skip khmer test on older 'broken' icu versions

Change-Id: Iab813f5288af1f0e054c022c4e4a99b92c7ce1ce

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index 68dc1ef..57c70e4 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -38,6 +38,8 @@
 #include com/sun/star/i18n/WordType.hpp
 #include unotest/bootstrapfixturebase.hxx
 
+#include unicode/uvernum.h
+
 #include rtl/strbuf.hxx
 #include rtl/ustrbuf.hxx
 
@@ -59,7 +61,9 @@ public:
 #if TODO
 void testNorthernThai();
 #endif
+#if (U_ICU_VERSION_MAJOR_NUM  4)
 void testKhmer();
+#endif
 
 CPPUNIT_TEST_SUITE(TestBreakIterator);
 CPPUNIT_TEST(testLineBreaking);
@@ -70,7 +74,9 @@ public:
 #if TODO
 CPPUNIT_TEST(testNorthernThai);
 #endif
+#if (U_ICU_VERSION_MAJOR_NUM  4)
 CPPUNIT_TEST(testKhmer);
+#endif
 CPPUNIT_TEST_SUITE_END();
 private:
 uno::Referencei18n::XBreakIterator m_xBreak;
@@ -343,8 +349,12 @@ void TestBreakIterator::testNorthernThai()
 }
 #endif
 
+#if (U_ICU_VERSION_MAJOR_NUM  4)
 //A test to ensure that our khmer word boundary detection is useful
 //https://bugs.freedesktop.org/show_bug.cgi?id=52020
+//
+//icu doesn't have the Khmer word boundary dictionaries in = 4.0.0 but does in
+//the current 49.x.y . Not sure which version first had them introduced.
 void TestBreakIterator::testKhmer()
 {
 lang::Locale aLocale;
@@ -364,6 +374,7 @@ void TestBreakIterator::testKhmer()
 
 CPPUNIT_ASSERT(aBounds.startPos == 3  aBounds.endPos == 5);
 }
+#endif
 
 void TestBreakIterator::setUp()
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa

2012-07-13 Thread Caolán McNamara
 i18npool/qa/cppunit/test_breakiterator.cxx |   43 +
 1 file changed, 43 insertions(+)

New commits:
commit 52280c29880c2d6bc533692d3f0cdff37f35790d
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Jul 13 12:49:28 2012 +0100

Related: fdo#49629 add test case for #i11993#

Change-Id: I4466b57514352620fd26072544ec6e50bf08708c

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index 57c70e4..a65d0b6 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -54,6 +54,7 @@ public:
 virtual void tearDown();
 
 void testLineBreaking();
+void testWordBoundaries();
 void testGraphemeIteration();
 void testWeak();
 void testAsian();
@@ -67,6 +68,7 @@ public:
 
 CPPUNIT_TEST_SUITE(TestBreakIterator);
 CPPUNIT_TEST(testLineBreaking);
+CPPUNIT_TEST(testWordBoundaries);
 CPPUNIT_TEST(testGraphemeIteration);
 CPPUNIT_TEST(testWeak);
 CPPUNIT_TEST(testAsian);
@@ -125,6 +127,47 @@ void TestBreakIterator::testLineBreaking()
 }
 }
 
+//See https://bugs.freedesktop.org/show_bug.cgi?id=49629
+void TestBreakIterator::testWordBoundaries()
+{
+lang::Locale aLocale;
+aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(en));
+aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(US));
+
+i18n::Boundary aBounds;
+
+//See https://issues.apache.org/ooo/show_bug.cgi?id=11993
+{
+::rtl::OUString aTest(abcd ef  ghi??? KLM);
+
+CPPUNIT_ASSERT(!m_xBreak-isBeginWord(aTest, 4, aLocale, 
i18n::WordType::DICTIONARY_WORD));
+CPPUNIT_ASSERT(m_xBreak-isEndWord(aTest, 4, aLocale, 
i18n::WordType::DICTIONARY_WORD));
+aBounds = m_xBreak-getWordBoundary(aTest, 4, aLocale, 
i18n::WordType::DICTIONARY_WORD, true);
+CPPUNIT_ASSERT(aBounds.startPos == 0  aBounds.endPos == 4);
+
+CPPUNIT_ASSERT(!m_xBreak-isBeginWord(aTest, 8, aLocale, 
i18n::WordType::DICTIONARY_WORD));
+CPPUNIT_ASSERT(!m_xBreak-isEndWord(aTest, 8, aLocale, 
i18n::WordType::DICTIONARY_WORD));
+
+//next word
+aBounds = m_xBreak-getWordBoundary(aTest, 8, aLocale, 
i18n::WordType::DICTIONARY_WORD, true);
+CPPUNIT_ASSERT(aBounds.startPos == 9  aBounds.endPos == 12);
+
+//previous word
+aBounds = m_xBreak-getWordBoundary(aTest, 8, aLocale, 
i18n::WordType::DICTIONARY_WORD, false);
+CPPUNIT_ASSERT(aBounds.startPos == 5  aBounds.endPos == 7);
+
+CPPUNIT_ASSERT(!m_xBreak-isBeginWord(aTest, 12, aLocale, 
i18n::WordType::DICTIONARY_WORD));
+CPPUNIT_ASSERT(m_xBreak-isEndWord(aTest, 12, aLocale, 
i18n::WordType::DICTIONARY_WORD));
+aBounds = m_xBreak-getWordBoundary(aTest, 12, aLocale, 
i18n::WordType::DICTIONARY_WORD, true);
+CPPUNIT_ASSERT(aBounds.startPos == 9  aBounds.endPos == 12);
+
+CPPUNIT_ASSERT(m_xBreak-isBeginWord(aTest, 16, aLocale, 
i18n::WordType::DICTIONARY_WORD));
+CPPUNIT_ASSERT(!m_xBreak-isEndWord(aTest, 16, aLocale, 
i18n::WordType::DICTIONARY_WORD));
+aBounds = m_xBreak-getWordBoundary(aTest, 16, aLocale, 
i18n::WordType::DICTIONARY_WORD, true);
+CPPUNIT_ASSERT(aBounds.startPos == 16  aBounds.endPos == 19);
+}
+}
+
 //See http://qa.openoffice.org/issues/show_bug.cgi?id=52
 //See https://bugs.freedesktop.org/show_bug.cgi?id=40292
 void TestBreakIterator::testGraphemeIteration()
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa

2012-07-13 Thread Caolán McNamara
 i18npool/qa/cppunit/test_breakiterator.cxx |   17 +
 1 file changed, 17 insertions(+)

New commits:
commit 2cf6778842d259d4e6e1a1f0e4c6c2ceab874eee
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Jul 13 13:00:29 2012 +0100

Related: fdo#49629 add test case for #i21907#

Change-Id: Ie1dd9091e4d8ee09c9a75eecf28fd6cd06ea1839

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index a65d0b6..491681c 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -166,6 +166,23 @@ void TestBreakIterator::testWordBoundaries()
 aBounds = m_xBreak-getWordBoundary(aTest, 16, aLocale, 
i18n::WordType::DICTIONARY_WORD, true);
 CPPUNIT_ASSERT(aBounds.startPos == 16  aBounds.endPos == 19);
 }
+
+//See https://issues.apache.org/ooo/show_bug.cgi?id=21907
+{
+::rtl::OUString aTest(b a?);
+
+CPPUNIT_ASSERT(m_xBreak-isBeginWord(aTest, 1, aLocale, 
i18n::WordType::ANY_WORD));
+CPPUNIT_ASSERT(m_xBreak-isBeginWord(aTest, 2, aLocale, 
i18n::WordType::ANY_WORD));
+CPPUNIT_ASSERT(m_xBreak-isBeginWord(aTest, 3, aLocale, 
i18n::WordType::ANY_WORD));
+
+CPPUNIT_ASSERT(m_xBreak-isBeginWord(aTest, 3, aLocale, 
i18n::WordType::ANYWORD_IGNOREWHITESPACES));
+
+CPPUNIT_ASSERT(m_xBreak-isEndWord(aTest, 1, aLocale, 
i18n::WordType::ANY_WORD));
+CPPUNIT_ASSERT(m_xBreak-isEndWord(aTest, 2, aLocale, 
i18n::WordType::ANY_WORD));
+CPPUNIT_ASSERT(m_xBreak-isEndWord(aTest, 3, aLocale, 
i18n::WordType::ANY_WORD));
+
+CPPUNIT_ASSERT(m_xBreak-isEndWord(aTest, 3, aLocale, 
i18n::WordType::ANYWORD_IGNOREWHITESPACES));
+}
 }
 
 //See http://qa.openoffice.org/issues/show_bug.cgi?id=52
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa

2012-07-13 Thread Caolán McNamara
 i18npool/qa/cppunit/test_breakiterator.cxx |   37 +
 1 file changed, 37 insertions(+)

New commits:
commit 413554a3bd3e7236bd60e4e36f063351f3d31293
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Jul 13 13:28:14 2012 +0100

Related: fdo#49629 add test case for #i14904#

Change-Id: I2bed0272eade44ab988f2cd9becb1f8ef0f232a9

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index 491681c..3c2ba50 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -183,6 +183,43 @@ void TestBreakIterator::testWordBoundaries()
 
 CPPUNIT_ASSERT(m_xBreak-isEndWord(aTest, 3, aLocale, 
i18n::WordType::ANYWORD_IGNOREWHITESPACES));
 }
+
+//See https://issues.apache.org/ooo/show_bug.cgi?id=14904
+{
+const sal_Unicode TEST1[] =
+{
+'W', 'o', 'r', 'k', 'i', 'n', 'g', ' ', 0x201C, 'W', 'o', 'r', 
'd', 's',
+' ', 's', 't', 'a', 'r', 't', 'i', 'n', 'g', ' ', 'w', 'i', 't',
+'h', ' ', 'q', 'u', 'o', 't', 'e', 's', 0x201D, ' ', 'W', 'o', 
'r', 'k',
+'i', 'n', 'g', ' ', 0x2018, 'B', 'r', 'o', 'k', 'e', 'n', 0x2019, 
' ',
+'?', 'S', 'p', 'a', 'n', 'i', 's', 'h', '?', ' ', 'd', 'o', 'e',
+'s', 'n', 0x2019, 't', ' ', 'w', 'o', 'r', 'k', '.', ' ', 'N', 'o',
+'t', ' ', 'e', 'v', 'e', 'n', ' ' , 0x00BF, 'r', 'e', 'a', 'l', 
'?', ' ',
+'S', 'p', 'a', 'n', 'i', 's', 'h'
+};
+::rtl::OUString aTest(TEST1, SAL_N_ELEMENTS(TEST1));
+
+aBounds = m_xBreak-getWordBoundary(aTest, 4, aLocale, 
i18n::WordType::DICTIONARY_WORD, false);
+CPPUNIT_ASSERT(aBounds.startPos == 0  aBounds.endPos == 7);
+
+aBounds = m_xBreak-getWordBoundary(aTest, 12, aLocale, 
i18n::WordType::DICTIONARY_WORD, false);
+CPPUNIT_ASSERT(aBounds.startPos == 9  aBounds.endPos == 14);
+
+aBounds = m_xBreak-getWordBoundary(aTest, 40, aLocale, 
i18n::WordType::DICTIONARY_WORD, false);
+CPPUNIT_ASSERT(aBounds.startPos == 37  aBounds.endPos == 44);
+
+aBounds = m_xBreak-getWordBoundary(aTest, 49, aLocale, 
i18n::WordType::DICTIONARY_WORD, false);
+CPPUNIT_ASSERT(aBounds.startPos == 46  aBounds.endPos == 52);
+
+aBounds = m_xBreak-getWordBoundary(aTest, 58, aLocale, 
i18n::WordType::DICTIONARY_WORD, false);
+CPPUNIT_ASSERT(aBounds.startPos == 55  aBounds.endPos == 62);
+
+aBounds = m_xBreak-getWordBoundary(aTest, 67, aLocale, 
i18n::WordType::DICTIONARY_WORD, false);
+CPPUNIT_ASSERT(aBounds.startPos == 64  aBounds.endPos == 71);
+
+aBounds = m_xBreak-getWordBoundary(aTest, 90, aLocale, 
i18n::WordType::DICTIONARY_WORD, false);
+CPPUNIT_ASSERT(aBounds.startPos == 88  aBounds.endPos == 92);
+}
 }
 
 //See http://qa.openoffice.org/issues/show_bug.cgi?id=52
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: i18npool/qa i18npool/source

2012-05-13 Thread Caolán McNamara
 i18npool/qa/cppunit/test_breakiterator.cxx  |   89 ++--
 i18npool/source/breakiterator/data/README   |   12 +++
 i18npool/source/breakiterator/data/line.txt |   57 +++--
 3 files changed, 105 insertions(+), 53 deletions(-)

New commits:
commit 20c24114143d6d38774b56a142fd4ae05094308e
Author: Caolán McNamara caol...@redhat.com
Date:   Sun May 13 22:41:30 2012 +0100

Resolves: fdo#49849 implement Unicode 6.1 hebrew line breaking rules

i.e.  sync with svn diff -c 31071

http://source.icu-project.org/repos/icu/icu/trunk/source/data/brkitr/line.txt

Change-Id: I I I41b3d02f1a0da3b83a9684f29d40d96254c6

diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx 
b/i18npool/qa/cppunit/test_breakiterator.cxx
index 14051d4..ffd590c 100644
--- a/i18npool/qa/cppunit/test_breakiterator.cxx
+++ b/i18npool/qa/cppunit/test_breakiterator.cxx
@@ -42,6 +42,7 @@
 #include unotest/bootstrapfixturebase.hxx
 
 #include rtl/strbuf.hxx
+#include rtl/ustrbuf.hxx
 
 #include string.h
 
@@ -58,6 +59,9 @@ public:
 void testWeak();
 void testAsian();
 void testThai();
+#if TODO
+void testNorthernThai();
+#endif
 
 CPPUNIT_TEST_SUITE(TestBreakIterator);
 CPPUNIT_TEST(testLineBreaking);
@@ -65,33 +69,54 @@ public:
 CPPUNIT_TEST(testWeak);
 CPPUNIT_TEST(testAsian);
 CPPUNIT_TEST(testThai);
+#if TODO
+CPPUNIT_TEST(testNorthernThai);
+#endif
 CPPUNIT_TEST_SUITE_END();
 private:
 uno::Referencei18n::XBreakIterator m_xBreak;
 };
 
-//See https://bugs.freedesktop.org/show_bug.cgi?id=31271
 void TestBreakIterator::testLineBreaking()
 {
-::rtl::OUString aTest(RTL_CONSTASCII_USTRINGPARAM((some text here)));
-
 i18n::LineBreakHyphenationOptions aHyphOptions;
 i18n::LineBreakUserOptions aUserOptions;
 lang::Locale aLocale;
 
-aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(en));
-aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(US));
-
+//See https://bugs.freedesktop.org/show_bug.cgi?id=31271
 {
-//Here we want the line break to leave text here) on the next line
-i18n::LineBreakResults aResult = m_xBreak-getLineBreak(aTest, 
strlen((some tex), aLocale, 0, aHyphOptions, aUserOptions);
-CPPUNIT_ASSERT_MESSAGE(Expected a break at the the start of the 
word, aResult.breakIndex == 6);
+::rtl::OUString aTest(RTL_CONSTASCII_USTRINGPARAM((some text here)));
+
+aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(en));
+aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(US));
+
+{
+//Here we want the line break to leave text here) on the next line
+i18n::LineBreakResults aResult = m_xBreak-getLineBreak(aTest, 
strlen((some tex), aLocale, 0, aHyphOptions, aUserOptions);
+CPPUNIT_ASSERT_MESSAGE(Expected a break at the the start of the 
word, aResult.breakIndex == 6);
+}
+
+{
+//Here we want the line break to leave here) on the next line
+i18n::LineBreakResults aResult = m_xBreak-getLineBreak(aTest, 
strlen((some text here), aLocale, 0, aHyphOptions, aUserOptions);
+CPPUNIT_ASSERT_MESSAGE(Expected a break at the the start of the 
word, aResult.breakIndex == 11);
+}
 }
 
+//See https://bugs.freedesktop.org/show_bug.cgi?id=49849
 {
-//Here we want the line break to leave here) on the next line
-i18n::LineBreakResults aResult = m_xBreak-getLineBreak(aTest, 
strlen((some text here), aLocale, 0, aHyphOptions, aUserOptions);
-CPPUNIT_ASSERT_MESSAGE(Expected a break at the the start of the 
word, aResult.breakIndex == 11);
+const sal_Unicode HEBREW1[] = { 0x05DE, 0x05D9, 0x05DC, 0x05D9, 0x5DD 
};
+::rtl::OUString aWord(HEBREW1, SAL_N_ELEMENTS(HEBREW1));
+::rtl::OUString aTest(rtl::OUStringBuffer(aWord).append(' 
').append(aWord).makeStringAndClear());
+
+aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(he));
+aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(IL));
+
+{
+//Here we want the line break to happen at the whitespace
+i18n::LineBreakResults aResult = m_xBreak-getLineBreak(aTest, 
aTest.getLength()-1, aLocale, 0, aHyphOptions, aUserOptions);
+CPPUNIT_ASSERT_MESSAGE(Expected a break at the the start of the 
word, aResult.breakIndex == aWord.getLength()+1);
+}
 }
 }
 
@@ -295,27 +320,29 @@ void TestBreakIterator::testThai()
 aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(th));
 aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(TH));
 
-i18n::Boundary aBounds;
-{
-const sal_Unicode THAI1[] = { 0x0E01, 0x0E38, 0x0E2B, 0x0E25, 0x0E32, 
0x0E1A };
-::rtl::OUString aTest(THAI1, SAL_N_ELEMENTS(THAI1));
-aBounds = m_xBreak-getWordBoundary(aTest, 0, aLocale,
-i18n::WordType::DICTIONARY_WORD,