wordpress-develop/tests/phpunit/tests/comment
Sergey Biryukov 5cb17e222d Comments: Make moderated or disallowed key check case-insensitive for non-Latin words.
The `check_comment()` and `wp_check_comment_disallowed_list()` functions are expected to be case-insensitive, but that only worked for words using Latin script and consisting of ASCII characters.

This commit adds the Unicode flag to the regular expression used for the check in these functions, so that both pattern and subject can be treated as UTF-8 strings.

Reference: [https://www.php.net/manual/en/reference.pcre.pattern.modifiers.php PHP Manual: Pattern Modifiers].

Follow-up to [984], [2075], [48121], [48575].

Props bonjour52, SergeyBiryukov.
Fixes #57207.

git-svn-id: https://develop.svn.wordpress.org/trunk@54888 602fd350-edb4-49c9-b593-d223f7449a82
2022-11-28 19:42:56 +00:00
..
checkComment.php Comments: Make moderated or disallowed key check case-insensitive for non-Latin words. 2022-11-28 19:42:56 +00:00
commentForm.php Comments: Return early from comment_form() if an invalid post ID is passed. 2022-10-11 15:43:04 +00:00
commentsOpen.php Tests: Use the factory method instead of the property. 2022-09-06 22:09:49 +00:00
commentsTemplate.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
dateQuery.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
getCommentAuthorEmailLink.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
getCommentAuthorUrl.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00
getCommentAuthorUrlLink.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
getCommentClass.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
getCommentCount.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00
getCommentExcerpt.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00
getCommentLink.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
getCommentReplyLink.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
getCommentsPagesCount.php Tests: Replace some occurrences of assertEquals() with assertSame(). 2022-10-07 01:02:07 +00:00
getLastCommentModified.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00
getPageOfComment.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
isAvatarCommentType.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
metaCache.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00
pingsOpen.php Tests: Use the factory method instead of the property. 2022-09-06 22:09:49 +00:00
query.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00
slashes.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
template.php Tests: Use the factory method instead of the property. 2022-09-06 22:09:49 +00:00
walker.php Code Modernization: Remove dynamic properties in Tests_Comment_Walker. 2022-08-24 14:03:12 +00:00
wpAllowComment.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
wpBatchUpdateCommentType.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00
wpCheckCommentDisallowedList.php Comments: Make moderated or disallowed key check case-insensitive for non-Latin words. 2022-11-28 19:42:56 +00:00
wpComment.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00
wpCountComments.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00
wpHandleCommentSubmission.php Tests: Move wp_handle_comment_submission() tests to the comment directory. 2022-10-27 15:01:31 +00:00
wpListComments.php Build/Test Tools: Add @covers tags to the comments tests. 2022-08-08 23:12:30 +00:00
wpUpdateCommentCountNow.php Tests: Rename classes in phpunit/tests/comment/ per the naming conventions. 2022-10-27 15:53:08 +00:00