ICU-5359 rbbi, port of C changes to Java, in progress.
X-SVN-Rev: 20218
This commit is contained in:
parent
383247126f
commit
d2974fef6a
@ -287,8 +287,9 @@ public void TestExtended() {
|
||||
}
|
||||
if (cp == CH_LF || cp == CH_CR) {
|
||||
lineNum++;
|
||||
colStart = charIdx;
|
||||
column = 0;
|
||||
charIdx++;
|
||||
colStart = charIdx;
|
||||
break;
|
||||
}
|
||||
|
||||
@ -374,6 +375,10 @@ void executeTest(TestParams t) {
|
||||
int prevBP;
|
||||
int i;
|
||||
|
||||
if (t.bi == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
t.bi.setText(t.dataToBreak.toString());
|
||||
//
|
||||
// Run the iterator forward
|
||||
@ -407,10 +412,11 @@ void executeTest(TestParams t) {
|
||||
if (expectedTagVal == -1) {
|
||||
expectedTagVal = 0;
|
||||
}
|
||||
int line = t.srcLine[bp];
|
||||
int rs = ((RuleBasedBreakIterator)t.bi).getRuleStatus();
|
||||
if (rs != expectedTagVal) {
|
||||
errln("Incorrect status for forward break. Pos= " + bp +
|
||||
"File line,col= " + t.srcLine[bp] + ", " + t.srcCol[bp] + "\n" +
|
||||
errln("Incorrect status for forward break. Pos = " + bp +
|
||||
". File line,col = " + line + ", " + t.srcCol[bp] + "\n" +
|
||||
" Actual, Expected status = " + rs + ", " + expectedTagVal);
|
||||
}
|
||||
}
|
||||
@ -459,10 +465,11 @@ void executeTest(TestParams t) {
|
||||
if (expectedTagVal == -1) {
|
||||
expectedTagVal = 0;
|
||||
}
|
||||
int line = t.srcLine[bp];
|
||||
int rs = ((RuleBasedBreakIterator)t.bi).getRuleStatus();
|
||||
if (rs != expectedTagVal) {
|
||||
errln("Incorrect status for reverse break. Pos= " + bp +
|
||||
"File line,col= " + t.srcLine[bp] + ", " + t.srcCol[bp] + "\n" +
|
||||
"File line,col= " + line + ", " + t.srcCol[bp] + "\n" +
|
||||
" Actual, Expected status = " + rs + ", " + expectedTagVal);
|
||||
}
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
# Copyright (c) 2001-2005 International Business Machines
|
||||
# Copyright (c) 2001-2006 International Business Machines
|
||||
# Corporation and others. All Rights Reserved.
|
||||
#
|
||||
# RBBI Test Data
|
||||
@ -23,10 +23,14 @@
|
||||
#
|
||||
|
||||
|
||||
# Temp debugging tests
|
||||
<line>
|
||||
# to test for bug #4097920
|
||||
<data>•dog,cat,mouse •(one)•(two)\n<100></data>
|
||||
# Temp debugging tests
|
||||
<sent>
|
||||
<data>• (This is it). •Testing the sentence iterator. •\
|
||||
"This isn't it." •Hi! \
|
||||
•This is a simple sample sentence. •(This is it.) •This is a simple sample sentence. •\
|
||||
"This isn't it." •\
|
||||
Hi! •This is a simple sample sentence. •It does not have to make any sense as you can see. •Nel mezzo del cammin di nostra vita, mi ritrovai in una selva oscura. •Che la dritta via aveo smarrita. •He said, that I said, that you said!! •Don't rock the boat.\u2029•Because I am the daddy, that is why.
|
||||
•Not on my time (el timo.)! •</data>
|
||||
|
||||
########################################################################################
|
||||
#
|
||||
@ -88,6 +92,8 @@
|
||||
# (Requires special casing in implementation, which is why it gets a test.)
|
||||
<data>•\uffff•\uffff• •a•</data>
|
||||
|
||||
# Treat Japanese Half Width voicing marks as combining
|
||||
<data>•A\uff9e•B\uff9f\uff9e\uff9f•C•</data>
|
||||
|
||||
########################################################################################
|
||||
#
|
||||
@ -186,6 +192,11 @@
|
||||
#
|
||||
<data>•\u8527<400>\u02ba<200>\u0027\u0d42•\u00b7•\u09ea<100></data>
|
||||
|
||||
#
|
||||
# Jitterbug 5276 - treat Japanese half width voicing marks as Grapheme Extend
|
||||
#
|
||||
<data>•A\uff9e\uff9fBC<200> •1\uff9e\uff9f23<100></data>
|
||||
|
||||
########################################################################################
|
||||
#
|
||||
#
|
||||
@ -218,19 +229,19 @@ doing? •This\n<100> costs $20,00,000. •</data>
|
||||
"This isn't it." •Hi! \
|
||||
•This is a simple sample sentence. •(This is it.) •This is a simple sample sentence. •\
|
||||
"This isn't it." •\
|
||||
Hi! •This is a simple sample sentence. •It does not have to make any sense as you can see. •Nel mezzo del cammin di nostra vita, mi ritrovai in una selva oscura. •Che la dritta via aveo smarrita. •He said, that I said, that you said!•! •Don't rock the boat.\u2029•Because I am the daddy, that is why.
|
||||
•Not on my time (el timo.)•! •</data>
|
||||
Hi! •This is a simple sample sentence. •It does not have to make any sense as you can see. •Nel mezzo del cammin di nostra vita, mi ritrovai in una selva oscura. •Che la dritta via aveo smarrita. •He said, that I said, that you said!! •Don't rock the boat.\u2029•Because I am the daddy, that is why.
|
||||
•Not on my time (el timo.)! •</data>
|
||||
|
||||
<data>•Hello. •So what!•!\u2029•"But now," he said, \
|
||||
<data>•Hello. •So what!!\u2029•"But now," he said, \
|
||||
"I know!" •\
|
||||
Harris thumbed down several, including "Away We Go" (which became the huge success Oklahoma!)•. •One species, B. anthracis, is highly virulent.
|
||||
Harris thumbed down several, including "Away We Go" (which became the huge success Oklahoma!). •One species, B. anthracis, is highly virulent.
|
||||
•Wolf said about Sounder:\
|
||||
"Beautifully thought-out and directed." •\
|
||||
Have you ever said, "This is where\tI shall live"? •He answered, \
|
||||
"You may not!" •Another popular saying is: "How do you do?"•. \n•\
|
||||
"You may not!" •Another popular saying is: "How do you do?". \n•\
|
||||
Yet another popular saying is: \
|
||||
'I'm fine thanks.' •\
|
||||
What is the proper use of the abbreviation pp.•? •Yes, I am definatelly 12" tall!•!\
|
||||
What is the proper use of the abbreviation pp.? •Yes, I am definatelly 12" tall!!\
|
||||
•Now\r<100>is\n<100>the\r\n<100>time\n<100>\r<100>for\r<100>\r<100></data>
|
||||
|
||||
<data>•No breaks when . is surrounded by UPPER.Case letters. •</data>
|
||||
@ -474,7 +485,7 @@ What is the proper use of the abbreviation pp.•? •Yes, I am definatelly 12"
|
||||
<data>•\u4e01•\ud840\udc01•\u4e02•abc •\ue000 •\udb80\udc01•</data>
|
||||
|
||||
# Regression for bug 836
|
||||
<data>•AAA•(AAA •</data>
|
||||
<data>•AAA(AAA •</data>
|
||||
|
||||
# Try some words from other scripts.
|
||||
# Greek, Cyrillic, Hebrew, Arabic, Arabic, Georgian, Latin
|
||||
@ -512,14 +523,17 @@ What is the proper use of the abbreviation pp.•? •Yes, I am definatelly 12"
|
||||
# Test data originally from the test code source file
|
||||
# // @suwit -- Thai sample data from GVT Guideline
|
||||
#
|
||||
<data>•\u0E2B\u0E19\u0E36\u0E48\u0E07•\u0E04\u0E33•\u0E44\u0E17\u0E22•\
|
||||
\u0E2A\u0E32\u0E21\u0E32\u0E23\u0E16•\u0E1B\u0E23\u0E30\u0E01\u0E2D\u0E1A•\
|
||||
\u0E14\u0E49\u0E27\u0E22•\u0e2b\u0e25\u0e32\u0e22•\
|
||||
\u0e1e\u0e22\u0e32\u0e07\u0e04\u0e4c•</data>
|
||||
# NOTE: Thai Java results differ from C because the new dictionary code is not
|
||||
# yet ported. All tags are zero with the old Thai impl.
|
||||
|
||||
<data>•\u0E2B\u0E19\u0E36\u0E48\u0E07<000>\u0E04\u0E33<000>\u0E44\u0E17\u0E22<000>\
|
||||
\u0E2A\u0E32\u0E21\u0E32\u0E23\u0E16<000>\u0E1B\u0E23\u0E30\u0E01\u0E2D\u0E1A<000>\
|
||||
\u0E14\u0E49\u0E27\u0E22<000>\u0e2b\u0e25\u0e32\u0e22<000>\
|
||||
\u0e1e\u0e22\u0e32\u0e07\u0e04\u0e4c<000></data>
|
||||
|
||||
#
|
||||
# Jitterbug 3671 Test Case
|
||||
#
|
||||
<data>•สวัสดี•ครับ•สบาย•ดี•ไหม• •ครับ•</data>
|
||||
<data>•สวัสดี<000>ครับ<000>สบาย<000>ดี<000>ไหม<000> •ครับ<000></data>
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user