MCPcopy Create free account
hub / github.com/apache/httpd / H2TestEnv

Class H2TestEnv

test/modules/http2/env.py:64–94  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

62
63
64class H2TestEnv(HttpdTestEnv):
65
66 @classmethod
67 def is_unsupported(cls):
68 mpm_module = f"mpm_{os.environ['MPM']}" if 'MPM' in os.environ else 'mpm_event'
69 return mpm_module == 'mpm_prefork'
70
71 def __init__(self, pytestconfig=None):
72 super().__init__(pytestconfig=pytestconfig)
73 self.add_httpd_conf([
74 "H2MinWorkers 1",
75 "H2MaxWorkers 64",
76 "Protocols h2 http/1.1 h2c",
77 ])
78 self.add_httpd_log_modules(["http2", "proxy_http2", "h2test", "proxy", "proxy_http"])
79 self.add_cert_specs([
80 CertificateSpec(domains=[
81 f"push.{self._http_tld}",
82 f"hints.{self._http_tld}",
83 f"ssl.{self._http_tld}",
84 f"pad0.{self._http_tld}",
85 f"pad1.{self._http_tld}",
86 f"pad2.{self._http_tld}",
87 f"pad3.{self._http_tld}",
88 f"pad8.{self._http_tld}",
89 ]),
90 CertificateSpec(domains=[f"noh2.{self.http_tld}"], key_type='rsa2048'),
91 ])
92
93 def setup_httpd(self, setup: HttpdTestSetup = None):
94 super().setup_httpd(setup=H2TestSetup(env=self))
95
96
97class H2Conf(HttpdConf):

Callers 2

pytest_report_headerFunction · 0.85
envFunction · 0.85

Calls

no outgoing calls

Tested by 2

pytest_report_headerFunction · 0.68
envFunction · 0.68