Add a test for same user returned twice in team sync

This commit is contained in:
Joseph Schorr 2017-03-07 14:36:56 -05:00
parent 0b6c062e32
commit 71d52d45ba

View file

@ -129,6 +129,16 @@ class FakeUsers(FederatedUsers):
UserInformation('someuser', 'someuser', 'someuser@devtable.com'),
],
['someuser', 'buynlarge+anotherbot']),
# Team which returns the same member twice, as pagination in some engines (like LDAP) is not
# stable.
([],
[
UserInformation('someuser', 'someuser', 'someuser@devtable.com'),
UserInformation('anotheruser', 'anotheruser', 'anotheruser@devtable.com'),
UserInformation('someuser', 'someuser', 'someuser@devtable.com'),
],
['anotheruser', 'someuser']),
])
def test_syncing(starting_membership, group_membership, expected_membership, app):
org = model.organization.get_organization('buynlarge')