7e1b55
From 9ae23e1257478bfee04b08b54f36dda7f5850348 Mon Sep 17 00:00:00 2001
7e1b55
From: =?UTF-8?q?Fran=C3=A7ois=20Cami?= <fcami@redhat.com>
7e1b55
Date: Thu, 5 Aug 2021 11:37:35 +0200
7e1b55
Subject: [PATCH] ipatests: use krb5_trace in TestIpaAdTrustInstall
7e1b55
MIME-Version: 1.0
7e1b55
Content-Type: text/plain; charset=UTF-8
7e1b55
Content-Transfer-Encoding: 8bit
7e1b55
7e1b55
tasks.create_active_user can fail in a subtle way when there
7e1b55
are two IPA servers due to replication delays.
7e1b55
Using the debug-enabled version of create_active_user helps
7e1b55
determine whether there is another underlying issue and, in
7e1b55
general, prevents the above problem.
7e1b55
7e1b55
Fixes: https://pagure.io/freeipa/issue/8944
7e1b55
Signed-off-by: François Cami <fcami@redhat.com>
7e1b55
Reviewed-By: Anuja More <amore@redhat.com>
7e1b55
---
7e1b55
 ipatests/test_integration/test_adtrust_install.py | 14 ++++++++++----
7e1b55
 1 file changed, 10 insertions(+), 4 deletions(-)
7e1b55
7e1b55
diff --git a/ipatests/test_integration/test_adtrust_install.py b/ipatests/test_integration/test_adtrust_install.py
7e1b55
index bbbb385a5..f23221186 100644
7e1b55
--- a/ipatests/test_integration/test_adtrust_install.py
7e1b55
+++ b/ipatests/test_integration/test_adtrust_install.py
7e1b55
@@ -257,8 +257,11 @@ class TestIpaAdTrustInstall(IntegrationTest):
7e1b55
         user_princ = '@'.join([user, self.master.domain.realm])
7e1b55
         passwd = 'Secret123'
7e1b55
         # Create a user with a password
7e1b55
-        tasks.create_active_user(self.master, user, passwd, extra_args=[
7e1b55
-            '--homedir', '/home/{}'.format(user)])
7e1b55
+        tasks.create_active_user(
7e1b55
+            self.master, user, passwd,
7e1b55
+            extra_args=["--homedir", "/home/{}".format(user)],
7e1b55
+            krb5_trace=True
7e1b55
+        )
7e1b55
         try:
7e1b55
             # Defaults: host/... principal for service
7e1b55
             # keytab in /etc/krb5.keytab
7e1b55
@@ -282,8 +285,11 @@ class TestIpaAdTrustInstall(IntegrationTest):
7e1b55
         user_princ = '@'.join([user, self.master.domain.realm])
7e1b55
         passwd = 'Secret123'
7e1b55
         # Create a user with a password
7e1b55
-        tasks.create_active_user(self.master, user, passwd, extra_args=[
7e1b55
-            '--homedir', '/home/{}'.format(user)])
7e1b55
+        tasks.create_active_user(
7e1b55
+            self.master, user, passwd,
7e1b55
+            extra_args=["--homedir", "/home/{}".format(user)],
7e1b55
+            krb5_trace=True
7e1b55
+        )
7e1b55
         try:
7e1b55
             # Defaults: host/... principal for service
7e1b55
             # keytab in /etc/krb5.keytab
7e1b55
-- 
7e1b55
2.31.1
7e1b55