From 4298fbc1a7f05a38f3f4270450f6972900b26ea5 Mon Sep 17 00:00:00 2001 From: vsedmik <46570670+vsedmik@users.noreply.github.com> Date: Tue, 28 May 2024 14:55:34 +0200 Subject: [PATCH] Fix content host finalizer (#15186) (cherry picked from commit 121a3d8d9be0b1b1d4829fa3b6539fb4718291e2) --- tests/foreman/ui/test_contenthost.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/foreman/ui/test_contenthost.py b/tests/foreman/ui/test_contenthost.py index 57260382b77..a90467ad7ce 100644 --- a/tests/foreman/ui/test_contenthost.py +++ b/tests/foreman/ui/test_contenthost.py @@ -815,7 +815,7 @@ def test_positive_check_ignore_facts_os_setting( # Change necessary setting to true set_ignore_facts_for_os(module_target_sat, True) # Add cleanup function to roll back setting to default value - request.addfinalizer(set_ignore_facts_for_os) + request.addfinalizer(lambda: set_ignore_facts_for_os(module_target_sat, False)) # Read all facts for corresponding host facts = host.get_facts(data={'per_page': 10000})['results'][vm.hostname] # Modify OS facts to another values and upload them to the server