ipatests: fix teardown method
The teardown method of the integration tests is calling
tasks.uninstall_master(replica)
which in turn does ipa server-del + ipa-server-install --uninstall
The uninstallation is called by default with --ignore-last-of-role
and --ignore-topology-disconnect excepted if the domain-level is 0,
in which case these options are not supported by uninstall.
The issue is that the call to get domain level fails because the
server has already been removed, and the code handles that failure by
assuming domain level =0, resulting in missing --ignore-last-of-role.
To workaround the issue, the call to tasks.uninstall should be done
with the actual domain level:
tasks.uninstall_master(replica, domain_level=...)
Fixes: https://pagure.io/freeipa/issue/8280
Reviewed-By: Sergey Orlov <sorlov@redhat.com>
Reviewed-By: Kaleemullah Siddiqui <ksiddiqu@redhat.com>