mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-10 07:39:16 +00:00
ICU-22848 Show the problem of infinity loop
Add test to show very slow creation
This commit is contained in:
parent
0bd2b4d10c
commit
7644adcaea
2 changed files with 9 additions and 0 deletions
icu4c/source/test/intltest
|
@ -155,6 +155,7 @@ void RBBITest::runIndexedTest( int32_t index, UBool exec, const char* &name, cha
|
|||
TESTCASE_AUTO(TestBug22585);
|
||||
TESTCASE_AUTO(TestBug22602);
|
||||
TESTCASE_AUTO(TestBug22636);
|
||||
TESTCASE_AUTO(TestBug22848);
|
||||
|
||||
#if U_ENABLE_TRACING
|
||||
TESTCASE_AUTO(TestTraceCreateCharacter);
|
||||
|
@ -6133,6 +6134,13 @@ void RBBITest::TestBug22636() {
|
|||
assertEquals(WHERE, ec, U_ZERO_ERROR);
|
||||
}
|
||||
|
||||
void RBBITest::TestBug22848() {
|
||||
if (quick || logKnownIssue("ICU-22848", "Very slow case")) { return; }
|
||||
UParseError pe {};
|
||||
UErrorCode ec {U_ZERO_ERROR};
|
||||
RuleBasedBreakIterator bi(u".*X..................;", pe, ec);
|
||||
}
|
||||
|
||||
void RBBITest::TestBug22584() {
|
||||
// Creating a break iterator from a rule consisting of a very long
|
||||
// literal input string caused a stack overflow when deleting the
|
||||
|
|
|
@ -106,6 +106,7 @@ public:
|
|||
void TestBug22585();
|
||||
void TestBug22602();
|
||||
void TestBug22636();
|
||||
void TestBug22848();
|
||||
|
||||
#if U_ENABLE_TRACING
|
||||
void TestTraceCreateCharacter();
|
||||
|
|
Loading…
Add table
Reference in a new issue