aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/test.py
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2025-03-13 16:40:15 +0900
committerOphestra <cat@gensokyo.uk>2025-03-13 16:40:15 +0900
commit2871426df2d7d19ca6921d74a5834a627b920de5 (patch)
treeae455ea86248d72b88656ca4f4a03ff66fb76b96 /test/test.py
parente048f31baad20e16d5b1f92e5a04091a82b5ee6d (diff)
test: print output of failed test
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'test/test.py')
-rw-r--r--test/test.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/test/test.py b/test/test.py
index ed9d2c1e..5a2ac246 100644
--- a/test/test.py
+++ b/test/test.py
@@ -79,8 +79,7 @@ machine.wait_for_unit("multi-user.target")
# Run fortify Go tests outside of nix build in the background:
machine.succeed("rm -rf /tmp/src && cp -a \"$(fortify-src)\" /tmp/src")
-machine.succeed(
- "fortify-fhs -c '(cd /tmp/src && go generate ./... && go test ./... && touch /tmp/success-gotest)' &> /tmp/gotest &")
+machine.succeed("fortify-fhs -c '(cd /tmp/src && go generate ./... && go test ./... && touch /tmp/success-gotest)' &> /tmp/gotest &")
# To check fortify's version:
print(machine.succeed("sudo -u alice -i fortify version"))
@@ -161,8 +160,7 @@ machine.wait_until_fails("pgrep foot", timeout=5)
machine.wait_until_fails("getfacl --absolute-names --omit-header --numeric /run/user/1000 | grep 1000002", timeout=5)
# Start app (foot) with Wayland enablement from a terminal:
-swaymsg(
- "exec foot $SHELL -c '(ne-foot) & sleep 1 && fortify show $(fortify ps --short) && touch /tmp/ps-show-ok && cat'")
+swaymsg("exec foot $SHELL -c '(ne-foot) & sleep 1 && fortify show $(fortify ps --short) && touch /tmp/ps-show-ok && cat'")
wait_for_window("u0_a2@machine")
machine.send_chars("clear; wayland-info && touch /tmp/success-client-term\n")
machine.wait_for_file("/tmp/fortify.1000/tmpdir/2/success-client-term", timeout=10)
@@ -219,5 +217,6 @@ machine.wait_for_file("/tmp/sway-exit-ok")
print(machine.succeed("find /run/user/1000/fortify"))
# Verify go test status:
-machine.wait_for_file("/tmp/success-gotest", timeout=5)
+machine.wait_for_file("/tmp/gotest", timeout=5)
print(machine.succeed("cat /tmp/gotest"))
+machine.wait_for_file("/tmp/success-gotest", timeout=5)