Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Sep 17, 2024
1 parent b5139f0 commit bb8474b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ldapauthenticator/ldapauthenticator.py
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ def _validate_bind_dn_template(self, proposal):
List of user attributes to be returned in auth_state
Will be available in `auth_state["user_attributes"]`
"""
""",
)

use_lookup_dn_username = Bool(
Expand Down
5 changes: 4 additions & 1 deletion ldapauthenticator/tests/test_ldapauthenticator.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ async def test_ldap_auth_search_filter(authenticator):
)
assert authorized is None


async def test_allow_config(authenticator):
# test various sources of allow config

Expand Down Expand Up @@ -167,7 +168,9 @@ async def test_ldap_auth_state_attributes(authenticator):
None, {"username": "fry", "password": "fry"}
)
assert authorized["name"] == "fry"
assert authorized["auth_state"]["user_attributes"] == {"employeeType": ["Delivery boy"]}
assert authorized["auth_state"]["user_attributes"] == {
"employeeType": ["Delivery boy"]
}


async def test_ldap_auth_state_attributes2(authenticator):
Expand Down

0 comments on commit bb8474b

Please sign in to comment.