diff --git a/test/pytest/test_certs.py b/test/pytest/test_certs.py index 427f6bd44101bf594cecf76f3cd349c047641ef9..5343122ec11115916089bf3d282550a7ce19af2f 100755 --- a/test/pytest/test_certs.py +++ b/test/pytest/test_certs.py @@ -12,7 +12,7 @@ from OpenSSL import SSL @pytest.mark.resource @pytest.mark.certs -def test_cert_validation(host, app): # pylint: disable=too-many-statements +def test_cert_validation(host, resource): # pylint: disable=too-many-statements """Checks for proper cluster certs from exposed services. Check is executed on the local provisioning machine. """ @@ -103,13 +103,13 @@ def test_cert_validation(host, app): # pylint: disable=too-many-statements 'wordpress': 'www' } - if app == 'all': + if resource == 'all': apps = list(app_subdomains.keys()) - elif app == 'kube-prometheus-stack': + elif resource == 'kube-prometheus-stack': apps = ['grafana', 'prometheus'] else: - assert app in app_subdomains, "Error: Unknown app: {}".format(app) - apps = [app] + assert resource in app_subdomains, "Error: Unknown app: {}".format(app) + apps = [resource] print('\n') for app_name in apps: @@ -127,4 +127,4 @@ def test_cert_validation(host, app): # pylint: disable=too-many-statements ['pytest/le-staging-bundle.pem']) fqdn = app_subdomains[app_name] + '.' + domain - assert valid_cert(domain=fqdn, app=app) + assert valid_cert(domain=fqdn, app=resource)