2
0

test_acme-http-challenge-location-legacy.py 776 B

1234567891011121314151617181920
  1. def test_redirect_acme_challenge_location_legacy(docker_compose, nginxproxy, acme_challenge_path):
  2. r = nginxproxy.get(
  3. f"http://web1.nginx-proxy.tld/{acme_challenge_path}",
  4. allow_redirects=False
  5. )
  6. assert r.status_code == 200
  7. def test_noredirect_acme_challenge_location_legacy(docker_compose, nginxproxy, acme_challenge_path):
  8. r = nginxproxy.get(
  9. f"http://web2.nginx-proxy.tld/{acme_challenge_path}",
  10. allow_redirects=False
  11. )
  12. assert r.status_code == 404
  13. def test_unknown_domain_acme_challenge_location_legacy(docker_compose, nginxproxy, acme_challenge_path):
  14. r = nginxproxy.get(
  15. f"http://web-unknown.nginx-proxy.tld/{acme_challenge_path}",
  16. allow_redirects=False
  17. )
  18. assert r.status_code == 503