remove distinction between dv_auth and auth

This commit is contained in:
Brad Warren
2016-03-01 14:53:10 -08:00
parent d3cc2b187c
commit 32c4f80117
2 changed files with 6 additions and 6 deletions
+5 -5
View File
@@ -162,7 +162,7 @@ class Client(object):
:ivar .AuthHandler auth_handler: Authorizations handler that will
dispatch DV and Continuity challenges to appropriate
authenticators (providing `.IAuthenticator` interface).
:ivar .IAuthenticator dv_auth: Prepared (`.IAuthenticator.prepare`)
:ivar .IAuthenticator auth: Prepared (`.IAuthenticator.prepare`)
authenticator that can solve the `.constants.DV_CHALLENGES`.
:ivar .IInstaller installer: Installer.
:ivar acme.client.Client acme: Optional ACME client API handle.
@@ -170,11 +170,11 @@ class Client(object):
"""
def __init__(self, config, account_, dv_auth, installer, acme=None):
def __init__(self, config, account_, auth, installer, acme=None):
"""Initialize a client."""
self.config = config
self.account = account_
self.dv_auth = dv_auth
self.auth = auth
self.installer = installer
# Initialize ACME if account is provided
@@ -182,9 +182,9 @@ class Client(object):
acme = acme_from_config_key(config, self.account.key)
self.acme = acme
if dv_auth is not None:
if auth is not None:
self.auth_handler = auth_handler.AuthHandler(
dv_auth, self.acme, self.account)
auth, self.acme, self.account)
else:
self.auth_handler = None
+1 -1
View File
@@ -107,7 +107,7 @@ class ClientTest(unittest.TestCase):
self.acme = acme.return_value = mock.MagicMock()
self.client = Client(
config=self.config, account_=self.account,
dv_auth=None, installer=None)
auth=None, installer=None)
def test_init_acme_verify_ssl(self):
net = self.acme_client.call_args[1]["net"]