Skip to content

Commit

Permalink
mod_md pytest: fix run on a clean test/gen to create
Browse files Browse the repository at this point in the history
all needed directories.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1920751 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
icing committed Sep 17, 2024
1 parent af10058 commit 7087372
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 3 deletions.
9 changes: 6 additions & 3 deletions test/modules/md/test_730_static.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ def test_md_730_001(self, env):
# MD with static cert files, will not be driven
domain = self.test_domain
domains = [domain, 'www.%s' % domain]
testpath = os.path.join(env.gen_dir, 'test_920_001')
testpath = os.path.join(env.gen_dir, 'test_730_001')
env.mkpath(testpath)
# cert that is only 10 more days valid
creds = env.create_self_signed_cert(CertificateSpec(domains=domains),
valid_from=timedelta(days=-80),
Expand Down Expand Up @@ -62,7 +63,8 @@ def test_md_730_002(self, env):
# MD with static cert files, force driving
domain = self.test_domain
domains = [domain, 'www.%s' % domain]
testpath = os.path.join(env.gen_dir, 'test_920_001')
testpath = os.path.join(env.gen_dir, 'test_730_002')
env.mkpath(testpath)
# cert that is only 10 more days valid
creds = env.create_self_signed_cert(CertificateSpec(domains=domains),
valid_from=timedelta(days=-80),
Expand Down Expand Up @@ -97,7 +99,8 @@ def test_md_730_003(self, env):
# just configuring one file will not work
domain = self.test_domain
domains = [domain, 'www.%s' % domain]
testpath = os.path.join(env.gen_dir, 'test_920_001')
testpath = os.path.join(env.gen_dir, 'test_730_003')
env.mkpath(testpath)
# cert that is only 10 more days valid
creds = env.create_self_signed_cert(CertificateSpec(domains=domains),
valid_from=timedelta(days=-80),
Expand Down
1 change: 1 addition & 0 deletions test/modules/md/test_801_stapling.py
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,7 @@ def test_md_801_009(self, env):
md = self.mdA
domains = [md]
testpath = os.path.join(env.gen_dir, 'test_801_009')
env.mkpath(testpath)
# cert that is 30 more days valid
creds = env.create_self_signed_cert(CertificateSpec(domains=domains),
valid_from=timedelta(days=-60),
Expand Down
2 changes: 2 additions & 0 deletions test/modules/md/test_901_message.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ def test_md_901_010(self, env):
domain = self.test_domain
domains = [domain, 'www.%s' % domain]
testpath = os.path.join(env.gen_dir, 'test_901_010')
env.mkpath(testpath)
# cert that is only 20 more days valid
creds = env.create_self_signed_cert(CertificateSpec(domains=domains),
valid_from=timedelta(days=-70),
Expand All @@ -182,6 +183,7 @@ def test_md_901_011(self, env):
domain = self.test_domain
domains = [domain, f'www.{domain}']
testpath = os.path.join(env.gen_dir, 'test_901_011')
env.mkpath(testpath)
# cert that is only 5 more days valid
creds = env.create_self_signed_cert(CertificateSpec(domains=domains),
valid_from=timedelta(days=-85),
Expand Down
1 change: 1 addition & 0 deletions test/modules/md/test_920_status.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ def test_md_920_011(self, env):
domain = self.test_domain
domains = [domain, 'www.%s' % domain]
testpath = os.path.join(env.gen_dir, 'test_920_011')
env.mkpath(testpath)
# cert that is only 20 more days valid
creds = env.create_self_signed_cert(CertificateSpec(domains=domains),
valid_from=timedelta(days=-70),
Expand Down

0 comments on commit 7087372

Please sign in to comment.