Skip to content

Commit

Permalink
Some minor unit test fixes and updates. (#761)
Browse files Browse the repository at this point in the history
  • Loading branch information
rwood-moz authored Nov 19, 2024
1 parent 8a1b5e3 commit f57569d
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion backend/test/unit/test_calendar_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def test_meeting_url_in_location(self, with_db, make_google_calendar, make_appoi

ics = Tools().create_vevent(appointment, slot, subscriber)
assert ics
assert ':'.join(['LOCATION', slot.meeting_link_url])
assert ':'.join(['LOCATION', slot.meeting_link_url]) in ics.decode()


class TestDnsCaldavLookup:
Expand Down
1 change: 1 addition & 0 deletions backend/test/unit/test_fxa_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ def test_is_in_allow_list(self, with_db):

test_email = 'cooltestguy@example.org'

# No allow list exists so everyone is allowed
assert fxa_client.is_in_allow_list(db, test_email)

# Domain is in allow list
Expand Down
4 changes: 4 additions & 0 deletions backend/test/unit/test_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,10 @@ def test_invited_user_remains_after_owner_is_deleted(self, with_db, make_basic_s
invite = db.query(models.Invite).filter(models.Invite.id == invite.id).first()
assert not invite

# Invited user should remain
inv_subscriber = db.query(models.Subscriber).filter(models.Subscriber.id == invited_subscriber.id).first()
assert inv_subscriber

def test_deleting_invited_user_deletes_invite_and_waiting_list(self, with_db, make_basic_subscriber, make_invite, make_waiting_list):
with with_db() as db:
subscriber = make_basic_subscriber()
Expand Down

0 comments on commit f57569d

Please sign in to comment.