URL: https://github.com/freeipa/freeipa/pull/1646 Author: felipevolpone Title: #1646: Fixing cleanup process in test_caless Action: opened
PR body: """ Fixing cleanup process in test_caless After commit bbe615e, if the uninstall process fails (in the test cleanup) the error is not hidden anymore. That brought light to errors in the cleanup process on `TestReplicaInstall` test, like this: ``` RUN ['ipa-server-install', '--uninstall', '-U'] ipapython.admintool: ERROR Server removal aborted: Replication topology in suffix 'domain' is disconnected: Topology does not allow server master.ipa.test to replicate with servers: replica0.ipa.test. ipapython.admintool: ERROR The ipa-server-install command failed ``` This commit changes the order of how a replica should be removed from the topology. Other errors can be checked [here](https://fedorapeople.org/groups/freeipa/prci/jobs/1b27ac12-1bfe-11e8-9b66-fa163e97f492/). """ To pull the PR as Git branch: git remote add ghfreeipa https://github.com/freeipa/freeipa git fetch ghfreeipa pull/1646/head:pr1646 git checkout pr1646
From 3f01916e30cc6c86e78e51f623ab7c9c4fc61900 Mon Sep 17 00:00:00 2001 From: Felipe Barreto <fbarr...@redhat.com> Date: Thu, 1 Mar 2018 19:19:05 -0300 Subject: [PATCH 1/2] Fixing cleanup process in test_caless After commit bbe615e12c278f9cddaeb38e80b970bf14d9b32d, if the uninstall process fails (in the test cleanup) the error is not hidden anymore. That brought light to errors in the cleanup process on TestReplicaInstall test, like this: ``` RUN ['ipa-server-install', '--uninstall', '-U'] ipapython.admintool: ERROR Server removal aborted: Replication topology in suffix 'domain' is disconnected: Topology does not allow server master.ipa.test to replicate with servers: replica0.ipa.test. ipapython.admintool: ERROR The ipa-server-install command failed ``` This commit changes the order of how a replica should be removed from the topology. --- ipatests/test_integration/test_caless.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/ipatests/test_integration/test_caless.py b/ipatests/test_integration/test_caless.py index 9be8c4f413..4d52309108 100644 --- a/ipatests/test_integration/test_caless.py +++ b/ipatests/test_integration/test_caless.py @@ -105,15 +105,14 @@ def wrapped(*args): replica = args[0].replicas[0] master = args[0].master tasks.kinit_admin(master) + tasks.clean_replication_agreement(master, replica, cleanup=True, + raiseonerr=False) + master.run_command(['ipa', 'host-del', replica.hostname], + raiseonerr=False) tasks.uninstall_master(replica, clean=False) # Now let's uninstall client for the cases when client promotion # was not successful tasks.uninstall_client(replica) - tasks.clean_replication_agreement(master, replica, cleanup=True, - raiseonerr=False) - master.run_command(['ipa', 'host-del', - replica.hostname], - raiseonerr=False) ipa_certs_cleanup(replica) return wrapped From c1845b76d40c9fc009685efd193960fa148d2695 Mon Sep 17 00:00:00 2001 From: Felipe Barreto <fbarr...@redhat.com> Date: Thu, 1 Mar 2018 19:22:24 -0300 Subject: [PATCH 2/2] Temporary commit: adding the test to run in PR CI --- .freeipa-pr-ci.yaml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.freeipa-pr-ci.yaml b/.freeipa-pr-ci.yaml index b98a27835c..9152a48ab6 100644 --- a/.freeipa-pr-ci.yaml +++ b/.freeipa-pr-ci.yaml @@ -62,3 +62,15 @@ jobs: template: *ci-master-f27 timeout: 3600 topology: *master_1repl + + fedora-27/TestReplicaInstall: + requires: [fedora-27/build] + priority: 50 + job: + class: RunPytest + args: + build_url: '{fedora-27/build_url}' + test_suite: test_integration/test_caless.py::TestReplicaInstall + template: *ci-master-f27 + timeout: 8000 + topology: *master_1repl
_______________________________________________ FreeIPA-devel mailing list -- freeipa-devel@lists.fedorahosted.org To unsubscribe send an email to freeipa-devel-le...@lists.fedorahosted.org