mirror of
https://github.com/systemd/systemd.git
synced 2025-03-09 12:58:26 +03:00
hostnamectl,localectl: use "(unset)" in empty fields
"n/a" is more ambiguous: not available or not set or maybe we didn't check it. Let's just say directly that the field is not set.
This commit is contained in:
parent
eb5b6b7310
commit
639405b934
@ -92,7 +92,7 @@ static int print_status_info(StatusInfo *i) {
|
|||||||
|
|
||||||
table_set_header(table, false);
|
table_set_header(table, false);
|
||||||
|
|
||||||
r = table_set_empty_string(table, "n/a");
|
r = table_set_empty_string(table, "(unset)");
|
||||||
if (r < 0)
|
if (r < 0)
|
||||||
return log_oom();
|
return log_oom();
|
||||||
|
|
||||||
|
@ -81,7 +81,7 @@ static int print_status_info(StatusInfo *i) {
|
|||||||
|
|
||||||
table_set_header(table, false);
|
table_set_header(table, false);
|
||||||
|
|
||||||
r = table_set_empty_string(table, "n/a");
|
r = table_set_empty_string(table, "(unset)");
|
||||||
if (r < 0)
|
if (r < 0)
|
||||||
return log_oom();
|
return log_oom();
|
||||||
|
|
||||||
|
@ -251,7 +251,7 @@ test_vc_keymap() {
|
|||||||
assert_in "X11 Variant: intl" "$output"
|
assert_in "X11 Variant: intl" "$output"
|
||||||
assert_in "X11 Options: terminate:ctrl_alt_bksp" "$output"
|
assert_in "X11 Options: terminate:ctrl_alt_bksp" "$output"
|
||||||
elif [[ "$i" =~ ^us-.* ]]; then
|
elif [[ "$i" =~ ^us-.* ]]; then
|
||||||
assert_in "X11 Layout: n/a" "$output"
|
assert_in "X11 Layout: .unset." "$output"
|
||||||
assert_not_in "X11 Model:" "$output"
|
assert_not_in "X11 Model:" "$output"
|
||||||
assert_not_in "X11 Variant:" "$output"
|
assert_not_in "X11 Variant:" "$output"
|
||||||
assert_not_in "X11 Options:" "$output"
|
assert_not_in "X11 Options:" "$output"
|
||||||
@ -262,7 +262,7 @@ test_vc_keymap() {
|
|||||||
systemctl stop systemd-localed.service
|
systemctl stop systemd-localed.service
|
||||||
wait_vconsole_setup
|
wait_vconsole_setup
|
||||||
rm -f /etc/vconsole.conf
|
rm -f /etc/vconsole.conf
|
||||||
assert_in "VC Keymap: n/a" "$(localectl)"
|
assert_in "VC Keymap: .unset." "$(localectl)"
|
||||||
}
|
}
|
||||||
|
|
||||||
test_x11_keymap() {
|
test_x11_keymap() {
|
||||||
@ -374,7 +374,7 @@ XKBMODEL=pc105+inet"
|
|||||||
systemctl stop systemd-localed.service
|
systemctl stop systemd-localed.service
|
||||||
rm -f /etc/X11/xorg.conf.d/00-keyboard.conf /etc/default/keyboard
|
rm -f /etc/X11/xorg.conf.d/00-keyboard.conf /etc/default/keyboard
|
||||||
output=$(localectl)
|
output=$(localectl)
|
||||||
assert_in "X11 Layout: n/a" "$output"
|
assert_in "X11 Layout: .unset." "$output"
|
||||||
assert_not_in "X11 Model:" "$output"
|
assert_not_in "X11 Model:" "$output"
|
||||||
assert_not_in "X11 Variant:" "$output"
|
assert_not_in "X11 Variant:" "$output"
|
||||||
assert_not_in "X11 Options:" "$output"
|
assert_not_in "X11 Options:" "$output"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user