mirror of
https://github.com/nginx-proxy/nginx-proxy
synced 2026-09-07 19:23:06 +02:00
20 lines
665 B
Python
20 lines
665 B
Python
from helpers import assert_ocsp_disabled, assert_ocsp_enabled
|
|
|
|
|
|
def test_ocsp_stapling_proxy_enabled_default_vhost(docker_compose, nginxproxy):
|
|
host = "ocsp-proxy-enabled-default.nginx-proxy.tld"
|
|
r = nginxproxy.get(f"http://{host}")
|
|
assert r.status_code == 200
|
|
|
|
conf = nginxproxy.get_conf().decode("ASCII")
|
|
assert_ocsp_enabled(conf, host)
|
|
|
|
|
|
def test_ocsp_stapling_proxy_enabled_vhost_disabled(docker_compose, nginxproxy):
|
|
host = "ocsp-proxy-enabled-vhost-disabled.nginx-proxy.tld"
|
|
r = nginxproxy.get(f"http://{host}")
|
|
assert r.status_code == 200
|
|
|
|
conf = nginxproxy.get_conf().decode("ASCII")
|
|
assert_ocsp_disabled(conf, host)
|