summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorFrantisek Sumsal <frantisek@sumsal.cz>2023-04-29 09:33:18 +0200
committerFrantisek Sumsal <frantisek@sumsal.cz>2023-04-29 16:58:40 +0200
commitedea0d6ac57610b7af603b833b19a846327e3638 (patch)
treee8214424515260385b844980ef113f68a886a432 /test
parent708d63c0e75b01d26edf4e4c85bd047bca410d44 (diff)
downloadsystemd-edea0d6ac57610b7af603b833b19a846327e3638.tar.gz
test: match all messages with the FILE field
As the systemd-pstore process is quite short lived, it might sometimes lack the necessary metadata to make matching against a unit or a syslog tag work. Since we already use a cursor file to make the matching window small as possible, let's just drop the unit match completely and hope for the best. Resolves: #27453
Diffstat (limited to 'test')
-rwxr-xr-xtest/units/testsuite-74.pstore.sh8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/units/testsuite-74.pstore.sh b/test/units/testsuite-74.pstore.sh
index b4e442c1be..b8bf5534a1 100755
--- a/test/units/testsuite-74.pstore.sh
+++ b/test/units/testsuite-74.pstore.sh
@@ -150,7 +150,7 @@ for unlink in yes no; do
[[ "$(file_count /sys/fs/pstore)" -ge "$exp_count" ]]
[[ "$(file_count /var/lib/systemd/pstore/)" -ne 0 ]]
# We always log to journal
- diff "$DUMMY_DMESG_1" <(journalctl -o cat -u systemd-pstore --output-fields=FILE --cursor-file=/tmp/journal.cursor | sed "/^$/d")
+ diff "$DUMMY_DMESG_1" <(journalctl -o cat --output-fields=FILE --cursor-file=/tmp/journal.cursor | sed "/^$/d")
filename="$(printf "/var/lib/systemd/pstore/%s/%0.3d/dmesg.txt" "$timestamp" "$(file_size "$DUMMY_DMESG_1")")"
diff "$DUMMY_DMESG_1" "$filename"
@@ -180,7 +180,7 @@ for unlink in yes no; do
start_pstore
[[ "$(file_count /sys/fs/pstore)" -ge "$exp_count" ]]
[[ "$(file_count /var/lib/systemd/pstore/)" -eq 0 ]]
- diff "$DUMMY_DMESG_1" <(journalctl -o cat -u systemd-pstore --output-fields=FILE --cursor-file=/tmp/journal.cursor | sed "/^$/d")
+ diff "$DUMMY_DMESG_1" <(journalctl -o cat --output-fields=FILE --cursor-file=/tmp/journal.cursor | sed "/^$/d")
: "Backend: ERST; Storage: external; Unlink: $unlink"
prepare_pstore_config "external" "$unlink"
@@ -190,7 +190,7 @@ for unlink in yes no; do
[[ "$(file_count /sys/fs/pstore)" -ge "$exp_count" ]]
[[ "$(file_count /var/lib/systemd/pstore/)" -ne 0 ]]
# We always log to journal
- diff "$DUMMY_DMESG_1" <(journalctl -o cat -u systemd-pstore --output-fields=FILE --cursor-file=/tmp/journal.cursor | sed "/^$/d")
+ diff "$DUMMY_DMESG_1" <(journalctl -o cat --output-fields=FILE --cursor-file=/tmp/journal.cursor | sed "/^$/d")
filename="$(printf "/var/lib/systemd/pstore/%0.16d/dmesg.txt" "$last_id")"
diff "$DUMMY_DMESG_1" "$filename"
@@ -217,5 +217,5 @@ for unlink in yes no; do
start_pstore
[[ "$(file_count /sys/fs/pstore)" -ge "$exp_count" ]]
[[ "$(file_count /var/lib/systemd/pstore/)" -eq 0 ]]
- diff "$DUMMY_DMESG_1" <(journalctl -o cat -u systemd-pstore --output-fields=FILE --cursor-file=/tmp/journal.cursor | sed "/^$/d")
+ diff "$DUMMY_DMESG_1" <(journalctl -o cat --output-fields=FILE --cursor-file=/tmp/journal.cursor | sed "/^$/d")
done