From: Luca Boccassi Date: Tue, 5 May 2026 18:24:41 +0000 (+0100) Subject: test: make TEST-04-JOURNAL.journalctl-varlink more robust (#41953) X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f149de5ce48b1059fe207a00e30b52c67a286ded;p=thirdparty%2Fsystemd.git test: make TEST-04-JOURNAL.journalctl-varlink more robust (#41953) This test is sometimes flaky under sanitizers, and it does repeated calls with the same parameters to run through different greps, and the second one sometimes fails. Store the result and grep it twice instead to try and reduce flakiness. ``` [ 2089.891152] TEST-04-JOURNAL.sh[22392]: + systemd-run --unit=test-journalctl-varlink-2-18237.service --wait bash -c 'echo hello-from-varlink-test-2' [ 2090.066050] TEST-04-JOURNAL.sh[22460]: + varlinkctl call --more /run/systemd/io.systemd.JournalAccess io.systemd.JournalAccess.GetEntries '{"units": ["test-journalctl-varlink-1-22690.service"]}' [ 2090.067075] TEST-04-JOURNAL.sh[22461]: + grep -q hello-from-varlink-test-1 [ 2090.384551] TEST-04-JOURNAL.sh[22466]: + varlinkctl call --more /run/systemd/io.systemd.JournalAccess io.systemd.JournalAccess.GetEntries '{"units": ["test-journalctl-varlink-1-22690.service"]}' [ 2090.385373] TEST-04-JOURNAL.sh[22467]: + grep hello-from-varlink-test-2 [ 2090.723461] TEST-04-JOURNAL.sh[22474]: + grep -q hello-from-varlink-test-1 [ 2090.724294] TEST-04-JOURNAL.sh[22473]: + varlinkctl call --more /run/systemd/io.systemd.JournalAccess io.systemd.JournalAccess.GetEntries '{"units": ["test-journalctl-varlink-1-22690.service", "test-journalctl-varlink-2-18237.service"]}' [ 2091.135655] TEST-04-JOURNAL.sh[22480]: + varlinkctl call --more /run/systemd/io.systemd.JournalAccess io.systemd.JournalAccess.GetEntries '{"units": ["test-journalctl-varlink-1-22690.service", "test-journalctl-varlink-2-18237.service"]}' [ 2091.136605] TEST-04-JOURNAL.sh[22481]: + grep -q hello-from-varlink-test-2 [ 2091.479930] TEST-04-JOURNAL.sh[22480]: Method call failed: io.systemd.JournalAccess.NoEntries ``` --- f149de5ce48b1059fe207a00e30b52c67a286ded