From 83a4b3c69c450ccf22bfcf9718bbccbe0df11427 Mon Sep 17 00:00:00 2001 From: Pablo Zmdl Date: Wed, 18 Sep 2024 20:06:31 +0200 Subject: [PATCH] Explicitly require mandatory locale for test This test works only if executed with LC_COLLATE=en_US --- tests/Framework/ImapTest.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/Framework/ImapTest.php b/tests/Framework/ImapTest.php index cd539302f24..0471e9f3cc0 100644 --- a/tests/Framework/ImapTest.php +++ b/tests/Framework/ImapTest.php @@ -47,6 +47,11 @@ public function test_convert_criteria() */ public function test_sort_folder_list() { + // The sorting requires this locale. + if (setlocale(\LC_ALL, 'en_US.UTF-8', 'en_US') === false) { + throw new \Error('This test requires `en_US.UTF-8` or `en_US` to be settable as locale, but those appear to not be present in your environment!'); + } + $_SESSION['imap_delimiter'] = '.'; $_SESSION['imap_namespace'] = [ 'personal' => null,