wordpress-develop/tests/phpunit/tests/l10n
Pascal Birchler 85e6518189 I18N: Ensure determine_locale() does not potentially return an empty string.
Call `get_locale()` as a last resort in case the sanitized locale is an empty string.

Also swaps conditionals to cater for more typical use case and adds tests.

Follow-up to [55862]

Props Cybr, swissspidy.
Fixes #58317.

git-svn-id: https://develop.svn.wordpress.org/trunk@56003 602fd350-edb4-49c9-b593-d223f7449a82
2023-06-23 16:01:08 +00:00
..
determineLocale.php I18N: Ensure determine_locale() does not potentially return an empty string. 2023-06-23 16:01:08 +00:00
getLocale.php Build/Test Tools: Add @covers tags to the l10n and i18n tests. 2022-08-08 23:39:06 +00:00
getUserLocale.php Tests: Correctly use the factory method. 2022-09-06 22:03:10 +00:00
loadScriptTextdomain.php Tests: Use the data_ prefix for various data provider methods. 2023-03-19 12:03:30 +00:00
loadTextdomain.php I18N: Allow to short-circuit load_textdomain(). 2023-06-16 12:56:03 +00:00
loadTextdomainJustInTime.php I18N: Improve _load_textdomain_just_in_time() logic when there are no translation files. 2023-05-29 08:34:43 +00:00
translateSettingsUsingI18nSchema.php Build/Test Tools: Add @covers tags to the l10n and i18n tests. 2022-08-08 23:39:06 +00:00
wpGetListItemSeparator.php I18N: Check that $wp_locale global is set before calling its methods. 2023-02-15 23:35:33 +00:00
wpGetWordCountType.php I18N: Check that $wp_locale global is set before calling its methods. 2023-02-15 23:35:33 +00:00
wpLocaleSwitcher.php I18N: Improve _load_textdomain_just_in_time() logic when there are no translation files. 2023-05-29 08:34:43 +00:00
wpTextdomainRegistry.php I18N: Change how WP_Textdomain_Registry caches translation information. 2022-12-20 15:10:35 +00:00