mirror of
https://github.com/certbot/certbot.git
synced 2026-06-03 13:59:02 -04:00
Make sure that configurator tests have the expected distro override
This commit is contained in:
parent
184925d241
commit
fee3fb6c33
2 changed files with 5 additions and 3 deletions
|
|
@ -41,6 +41,9 @@ class MultipleVhostsTest(util.ApacheTest):
|
|||
"""Mock default vhost path"""
|
||||
if key == "vhost_root":
|
||||
return vhost_path
|
||||
elif key == "override_class":
|
||||
from certbot_apache import override_debian
|
||||
return override_debian.Override
|
||||
else:
|
||||
return orig_os_constant(key)
|
||||
|
||||
|
|
@ -483,9 +486,6 @@ class MultipleVhostsTest(util.ApacheTest):
|
|||
mock_p = "certbot_apache.configurator.ApacheConfigurator._get_ssl_vhost_path"
|
||||
mock_a = "certbot_apache.parser.ApacheParser.add_include"
|
||||
|
||||
from certbot_apache import override_debian
|
||||
self.config.os_info = override_debian.Override(self.config)
|
||||
|
||||
with mock.patch("os.path.isdir") as mock_osp:
|
||||
mock_osp.return_value = False
|
||||
with mock.patch(mock_p) as mock_path:
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ from certbot.plugins import common_test
|
|||
|
||||
from certbot_apache import obj
|
||||
from certbot_apache.tests import util
|
||||
from certbot_apache import override_debian
|
||||
|
||||
from six.moves import xrange # pylint: disable=redefined-builtin, import-error
|
||||
|
||||
|
|
@ -25,6 +26,7 @@ class TlsSniPerformTest(util.ApacheTest):
|
|||
config = util.get_apache_configurator(
|
||||
self.config_path, self.vhost_path, self.config_dir, self.work_dir)
|
||||
config.config.tls_sni_01_port = 443
|
||||
config.os_info = override_debian.Override(config)
|
||||
|
||||
from certbot_apache import tls_sni_01
|
||||
self.sni = tls_sni_01.ApacheTlsSni01(config)
|
||||
|
|
|
|||
Loading…
Reference in a new issue