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

Method test_md_901_001

test/modules/md/test_901_message.py:37–60  ·  view source on GitHub ↗
(self, env)

Source from the content-addressed store, hash-verified

35
36 # test: signup with configured message cmd that is invalid
37 def test_md_901_001(self, env):
38 domain = self.test_domain
39 domains = [domain, "www." + domain]
40 conf = MDConf(env)
41 conf.add("MDMessageCmd blablabla")
42 conf.add_drive_mode("auto")
43 conf.add_md(domains)
44 conf.add_vhost(domains)
45 conf.install()
46 assert env.apache_restart() == 0, f'{env.apachectl_stderr}'
47 assert env.await_file(env.store_staged_file(domain, 'job.json'))
48 stat = env.get_md_status(domain)
49 # this command should have failed and logged an error
50 assert stat["renewal"]["last"]["problem"] == "urn:org:apache:httpd:log:AH10109:"
51 #
52 env.httpd_error_log.ignore_recent(
53 lognos = [
54 "AH10056" # None of the offered challenge types
55 ],
56 matches = [
57 r'.*urn:org:apache:httpd:log:AH10109:.*',
58 r'.*problem\[challenge-setup-failure\].*'
59 ]
60 )
61
62 # test: signup with configured message cmd that is valid but returns != 0
63 def test_md_901_002(self, env):

Callers

nothing calls this directly

Calls 11

add_drive_modeMethod · 0.95
add_mdMethod · 0.95
MDConfClass · 0.85
addMethod · 0.80
add_vhostMethod · 0.80
installMethod · 0.80
apache_restartMethod · 0.80
await_fileMethod · 0.80
store_staged_fileMethod · 0.80
get_md_statusMethod · 0.80
ignore_recentMethod · 0.80

Tested by

no test coverage detected