[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[CI 01/17] tests: Make sure LANG is set properly for iso9660_test
From: |
Glenn Washburn |
Subject: |
[CI 01/17] tests: Make sure LANG is set properly for iso9660_test |
Date: |
Thu, 18 Feb 2021 20:59:20 -0600 |
LANG must be set to something that supports international characters,
otherwise xorriso will refuse to include the file with name having
international characters, causing the test to fail. So if LANG is not set,
set it to en_US.UTF-8, a very common UTF-8 locale. And if it is set, but
does not look like a UTF-8 locale, print a warning so the user will have a
clue as to why the iso9660_test might be failing.
Signed-off-by: Glenn Washburn <development@efficientek.com>
---
tests/iso9660_test.in | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/tests/iso9660_test.in b/tests/iso9660_test.in
index 571b938d7..37b1d30af 100644
--- a/tests/iso9660_test.in
+++ b/tests/iso9660_test.in
@@ -7,6 +7,12 @@ if ! which xorriso >/dev/null 2>&1; then
exit 77
fi
+if [ -z "$LANG" ]; then
+ export LANG=en_US.UTF-8
+elif [ -n "${LANG##*UTF*}" ]; then
+ echo "WARNING: LANG=$LANG appears to not be unicode, international file
test may fail."
+fi
+
"@builddir@/grub-fs-tester" joliet
"@builddir@/grub-fs-tester" rockridge
"@builddir@/grub-fs-tester" rockridge_joliet
--
2.27.0
- [CI 00/17] Gitlab CI and test framework improvements, Glenn Washburn, 2021/02/18
- [CI 01/17] tests: Make sure LANG is set properly for iso9660_test,
Glenn Washburn <=
- [CI 02/17] tests: Fix partmap_test for arm*-efi, disk numbering has changed, Glenn Washburn, 2021/02/18
- [CI 03/17] tests: When checking squashfs fstime, use superblock last modified time, Glenn Washburn, 2021/02/18
- [CI 04/17] tests: Fail immediately when grub-shell fails and do not occlude the error code, Glenn Washburn, 2021/02/18
- [CI 05/17] grub-shell: Allow specifying non-default trim line contents, Glenn Washburn, 2021/02/18
- [CI 07/17] grub-shell: Only show grub-mkrescue output if it returns an error, Glenn Washburn, 2021/02/18
- [CI 08/17] grub-shell: Allow setting default timeout via GRUB_SHELL_DEFAULT_TIMEOUT envvar, Glenn Washburn, 2021/02/18
- [CI 06/17] grub-shell: Trim line should always be matched from the beginning of the line, Glenn Washburn, 2021/02/18
- [CI 10/17] grub-shell: Add grub output logfile with grub-shell --debug, Glenn Washburn, 2021/02/18
- [CI 11/17] grub-shell: Set exit status to qemu exit status, Glenn Washburn, 2021/02/18
- [CI 12/17] tests: Allow turning on shell tracing from environment variables, Glenn Washburn, 2021/02/18