mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
The fixture issue_and_expire_acme_cert returns a function that fills the hosts array. If the function is not called in the test (for instance because a test is skipped, as in TestACMEPrune::test_prune_cert_search_size_limit), hosts = [] and hosts[0] raises an IndexError. Fix the fixture to check first that hosts is not empty. Related: https://pagure.io/freeipa/issue/9348 Signed-off-by: Florence Blanc-Renaud <flo@redhat.com> Reviewed-By: Mohammad Rizwan Yusuf <myusuf@redhat.com>