From 88b3213af419dff2e4eabc8fa84ad81ce57b1302 Mon Sep 17 00:00:00 2001 From: Adam Williamson Date: Sat, 23 Dec 2023 12:04:50 -0800 Subject: [PATCH] autocloud: only run atomic test on canned (==atomic) installs It seems Python 3.12.1 changed unittests' behaviour so that all tests being skipped is now a fail not a pass. That breaks this test because TestAtomic01Status only does anything if this is an atomic system. So, let's just skip that test entirely if we aren't one. As things stand this means the test will never run, because we only test on Cloud_Base which is not atomic. Signed-off-by: Adam Williamson --- tests/autocloud.pm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/autocloud.pm b/tests/autocloud.pm index 087c5d2a..37bb7a88 100644 --- a/tests/autocloud.pm +++ b/tests/autocloud.pm @@ -26,7 +26,9 @@ sub run { console_login(user => "test", password => "weakpassword"); assert_script_run "curl -O https://fedorapeople.org/groups/qa/tunirtests.tar.gz"; assert_script_run "tar xvf tunirtests.tar.gz"; - assert_script_run "sudo python3 -m unittest tunirtests.atomictests.TestAtomic01Status -v"; + if (get_var("CANNED")) { + assert_script_run "sudo python3 -m unittest tunirtests.atomictests.TestAtomic01Status -v"; + } _soft_fail_run "tunirtests.nongatingtests.TunirNonGatingtests"; _soft_fail_run "tunirtests.nongatingtests.TunirNonGatingtestBzip2"; _soft_fail_run "tunirtests.nongatingtests.TunirNonGatingtestsCpio";