Skip to content

Commit

Permalink
new test helper function to add additional users
Browse files Browse the repository at this point in the history
cullerton committed Jan 22, 2025

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent 007f2f5 commit 8e5a20f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/base_test.py
Original file line number Diff line number Diff line change
@@ -150,6 +150,13 @@ def delete_example_data(self, use_crc_data=False, use_rrt_data=False):
"""
ExampleDataLoader.clean_db()

@staticmethod
def add_user(ldap_model):
db.session.add(ldap_model)
db.session.commit()
db.session.add(UserModel(uid=ldap_model.uid, ldap_info=ldap_model))


def add_users(self):
for user_json in self.users:
ldap_info = LdapService.user_info(user_json['uid'])

0 comments on commit 8e5a20f

Please sign in to comment.