Skip to content
This repository has been archived by the owner on Feb 8, 2018. It is now read-only.

Commit

Permalink
Failing tests for lookup.json restrictions
Browse files Browse the repository at this point in the history
  • Loading branch information
chadwhitacre committed Aug 3, 2016
1 parent 064b88c commit c0cf218
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions tests/py/test_lookup_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,25 @@ def test_looking_up_searchable_user_with_an_exact_match_finds_them(self):
def test_looking_up_searchable_user_without_an_exact_match_finds_them(self):
alice = self.make_participant("alice", claimed_time='now')
assert self.lookup('alic') == [alice.id, -1]


def test_looking_up_suspicious_user_finds_nothing(self):
self.make_participant( "alice"
, claimed_time='now'
, verified_in='TT'
, email_address='[email protected]'
, is_suspicious=True
)
assert self.lookup('alice') == []

def test_looking_up_unverified_user_finds_nothing(self):
self.make_participant("alice", claimed_time='now', email_address='[email protected]')
assert self.lookup('alice') == []

def test_looking_up_user_with_no_email_finds_nothing(self):
self.make_participant("alice", claimed_time='now') # can't verify w/o email!
assert self.lookup('alice') == []

def test_looking_up_unclaimed_user_finds_nothing(self):
self.make_participant("alice", verified_in='TT', email_address='[email protected]')
assert self.lookup('alice') == []

0 comments on commit c0cf218

Please sign in to comment.