URL: https://github.com/freeipa/freeipa/pull/3742 Author: flo-renaud Title: #3742: iptests: fix test_replica_promotion.py::TestHiddenReplicaPromotion Action: opened
PR body: """ The test test_replica_promotion.py::TestHiddenReplicaPromotion randomly fails in nightly_f29.
The test is checking that a given IP address is not in the DNS records for the domain. When we are unlucky, we may come up with the following situation: - IP address that is unexpected: 192.168.121.25 - IP address that is found for the DNS record: 192.168.121.254
As 192.168.121.25 is a substring of 192.168.121.254, the test wrongly considers that the unexpected address was found. Extract of the log: ``` for host in hosts_unexpected: value = host.hostname if rtype == 'SRV' else host.ip
assert value not in txt
E AssertionError: assert '192.168.121.25' not in 'ipa-ca.ipa.test. 1 IN A 192.168.121.254' E '192.168.121.25' is contained here: E ipa-ca.ipa.test. 1 IN A 192.168.121.254 E ? ++++++++++++++ ```
This happens because the test is comparing the content of the output as a string. The fix is extracting the exact hostname/IP address from the record instead.
Fixes: https://pagure.io/freeipa/issue/8070 """
To pull the PR as Git branch: git remote add ghfreeipa https://github.com/freeipa/freeipa git fetch ghfreeipa pull/3742/head:pr3742 git checkout pr3742
URL: https://github.com/freeipa/freeipa/pull/3742 Author: flo-renaud Title: #3742: ipatests: fix test_replica_promotion.py::TestHiddenReplicaPromotion Action: closed
To pull the PR as Git branch: git remote add ghfreeipa https://github.com/freeipa/freeipa git fetch ghfreeipa pull/3742/head:pr3742 git checkout pr3742
freeipa-devel@lists.fedorahosted.org