Skip to content

Commit

Permalink
Fix kernel tainted test (#3818)
Browse files Browse the repository at this point in the history
I have only tested that it fails for unreleased 6.6.72 kernel but haven't
tested the happy path and missed that it also failed because the types were
different. Stupid me.
  • Loading branch information
sairon authored Jan 21, 2025
1 parent 48bf9b5 commit 8233cb9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tests/smoke_test/test_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,4 +83,4 @@ def test_kernel_not_tainted(shell):
"""Check if the kernel is not tainted - do it at the end of the
test suite to increase the chance of catching issues."""
output = shell.run_check("cat /proc/sys/kernel/tainted")
assert output == "0\n", f"Kernel tainted: {output}"
assert "\n".join(output) == "0", f"Kernel tainted: {output}"
2 changes: 1 addition & 1 deletion tests/supervisor_test/test_supervisor.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,4 +197,4 @@ def test_kernel_not_tainted(shell):
"""Check if the kernel is not tainted - do it at the end of the
test suite to increase the chance of catching issues."""
output = shell.run_check("cat /proc/sys/kernel/tainted")
assert output == "0\n", f"Kernel tainted: {output}"
assert "\n".join(output) == "0", f"Kernel tainted: {output}"

0 comments on commit 8233cb9

Please sign in to comment.