diff --git a/0018-ipatests-fix-tasks-wait_for_replication-method_rhel#25708.patch b/0018-ipatests-fix-tasks-wait_for_replication-method_rhel#25708.patch new file mode 100644 index 0000000..c433849 --- /dev/null +++ b/0018-ipatests-fix-tasks-wait_for_replication-method_rhel#25708.patch @@ -0,0 +1,34 @@ +From 44a762413c83f9637399afeb61b1e4b1ac111260 Mon Sep 17 00:00:00 2001 +From: Florence Blanc-Renaud +Date: Feb 14 2024 12:24:48 +0000 +Subject: ipatests: fix tasks.wait_for_replication method + + +With the fix for https://pagure.io/freeipa/issue/9171, the +method entry.single_value['nsds5replicaupdateinprogress'] now +returns a Boolean instead of a string "TRUE"/"FALSE". + +The method tasks.wait_for_replication needs to be fixed so that +it properly detects when replication is not done. + +Fixes: https://pagure.io/freeipa/issue/9530 + +Signed-off-by: Florence Blanc-Renaud +Reviewed-By: Rob Crittenden + +--- + +diff --git a/ipatests/pytest_ipa/integration/tasks.py b/ipatests/pytest_ipa/integration/tasks.py +index 9068ba6..952c9e6 100755 +--- a/ipatests/pytest_ipa/integration/tasks.py ++++ b/ipatests/pytest_ipa/integration/tasks.py +@@ -1510,7 +1510,7 @@ def wait_for_replication(ldap, timeout=30, + statuses = [entry.single_value[status_attr] for entry in entries] + wrong_statuses = [s for s in statuses + if not re.match(target_status_re, s)] +- if any(e.single_value[progress_attr] == 'TRUE' for e in entries): ++ if any(e.single_value[progress_attr] for e in entries): + msg = 'Replication not finished' + logger.debug(msg) + elif wrong_statuses: + diff --git a/ipa.spec b/ipa.spec index c4f82e2..8b7e68f 100644 --- a/ipa.spec +++ b/ipa.spec @@ -225,6 +225,7 @@ Patch0014: 0014-krb5kdc-Fix-start-when-pkinit-and-otp-auth-type-are-enabled Patch0015: 0015-hbactest-was-not-collecting-or-returning-messages_rhel#12780.patch Patch0016: 0016-ipatests-wait-for-replica-update-in-test_dns_locatio.patch Patch0017: 0017-ipa-kdb-Rework-ipadb_reinit_mspac.patch +Patch0018: 0018-ipatests-fix-tasks-wait_for_replication-method_rhel#25708.patch %if 0%{?rhel} >= 8 Patch1001: 1001-Change-branding-to-IPA-and-Identity-Management.patch Patch1002: 1002-Revert-freeipa.spec-depend-on-bind-dnssec-utils.patch @@ -1740,11 +1741,13 @@ fi %endif %changelog -* Thu Feb 15 2024 Julien Rische - 4.9.13-6 +* Fri Feb 16 2024 Julien Rische - 4.9.13-6 - ipa-kdb: Rework ipadb_reinit_mspac() Resolves: RHEL-25742 - ipatests: wait for replica update in test_dns_locations Resolves: RHEL-22373 +- ipatests: fix tasks.wait_for_replication() method + Resolves: RHEL-25708 * Tue Feb 13 2024 Rafael Jeffman - 4.9.13-5 - kdb: PAC generator: do not fail if canonical principal is missing