mirror of
https://github.com/jupyterhub/the-littlest-jupyterhub.git
synced 2025-12-18 21:54:05 +08:00
Add NativeAuth as an optional authenticator
This commit is contained in:
@@ -159,3 +159,19 @@ def test_auth_github():
|
||||
assert c.JupyterHub.authenticator_class == 'oauthenticator.github.GitHubOAuthenticator'
|
||||
assert c.GitHubOAuthenticator.client_id == 'something'
|
||||
assert c.GitHubOAuthenticator.client_secret == 'something-else'
|
||||
|
||||
|
||||
def test_auth_native():
|
||||
"""
|
||||
Test setting Native Authenticator
|
||||
"""
|
||||
c = apply_mock_config({
|
||||
'auth': {
|
||||
'type': 'nativeauthenticator.NativeAuthenticator',
|
||||
'NativeAuthenticator': {
|
||||
'open_signup': True,
|
||||
}
|
||||
}
|
||||
})
|
||||
assert c.JupyterHub.authenticator_class == 'nativeauthenticator.NativeAuthenticator'
|
||||
assert c.NativeAuthenticator.open_signup == True
|
||||
|
||||
Reference in New Issue
Block a user