TESTCASE_AUTO(testBug12153);
TESTCASE_AUTO(testBug12825);
TESTCASE_AUTO(testBug12815);
+ TESTCASE_AUTO(testBug13314_MixedNumbers);
TESTCASE_AUTO_END;
}
TEST_ASSERT_SUCCESS(status);
}
+void IntlTestSpoof::testBug13314_MixedNumbers() {
+ UErrorCode status = U_ZERO_ERROR;
+ LocalUSpoofCheckerPointer sc(uspoof_open(&status));
+ TEST_ASSERT_SUCCESS(status);
+ uspoof_setChecks(sc.getAlias(), USPOOF_ALL_CHECKS, &status);
+ TEST_ASSERT_SUCCESS(status);
+ int32_t failedChecks = uspoof_areConfusableUnicodeString(sc.getAlias(), u"列", u"列", &status);
+ TEST_ASSERT_SUCCESS(status);
+ assertEquals("The CJK strings should be confusable", USPOOF_SINGLE_SCRIPT_CONFUSABLE, failedChecks);
+ failedChecks = uspoof_check2UnicodeString(sc.getAlias(), u"3Ȝ", nullptr, &status);
+ TEST_ASSERT_SUCCESS(status);
+ assertEquals("The '33' string does not fail spoof", 0, failedChecks);
+}
+
#endif /* !UCONFIG_NO_REGULAR_EXPRESSIONS && !UCONFIG_NO_NORMALIZATION && !UCONFIG_NO_FILE_IO */
void testBug12815();
+ void testBug13314_MixedNumbers();
+
// Internal function to run a single skeleton test case.
void checkSkeleton(const USpoofChecker *sc, uint32_t flags,
const char *input, const char *expected, int32_t lineNum);