From e3eba7b861b274dce00439cf29a016bc38e671e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Gajdu=C5=A1ek?= Date: Fri, 14 Jun 2024 14:31:40 +0200 Subject: [PATCH] Fix validation: validate IPv6 proxy URL only when IS_IPV6 is set to True --- robottelo/config/validators.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/robottelo/config/validators.py b/robottelo/config/validators.py index 1c37d63404f..2ae4c42ac04 100644 --- a/robottelo/config/validators.py +++ b/robottelo/config/validators.py @@ -36,7 +36,12 @@ Validator('server.ssh_password', default=None), Validator('server.verify_ca', default=False), Validator('server.is_ipv6', is_type_of=bool, default=False), - Validator('server.http_proxy_ipv6_url', is_type_of=str, default=None), + # validate http_proxy_ipv6_url only if is_ipv6 is True + Validator( + 'server.http_proxy_ipv6_url', + is_type_of=str, + when=Validator('server.is_ipv6', eq=True), + ), ], content_host=[ Validator('content_host.default_rhel_version', must_exist=True),