Skip to content

Commit

Permalink
rtip backend test case index fixing
Browse files Browse the repository at this point in the history
  • Loading branch information
msmannan00 committed Jan 9, 2025
1 parent 1451e4e commit ad38c9f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions backend/globaleaks/tests/handlers/recipient/test_rtip.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,9 +283,10 @@ def test_silence_notify(self):
def test_delete(self):
rtip_descs = yield self.get_rtips()
self.assertEqual(len(rtip_descs), self.population_of_submissions * self.population_of_recipients)

receiver_name = '[email protected]'
receiver = next((r for r in rtip_descs[0]['receivers'] if r['name'] == receiver_name), None)
# we delete the first and then we verify that the second does not exist anymore
handler = self.request(role='receiver', user_id=rtip_descs[0]['receiver_id'])
handler = self.request(role='receiver', user_id=receiver['id'])
yield handler.delete(rtip_descs[0]['id'])

rtip_descs = yield self.get_rtips()
Expand Down

0 comments on commit ad38c9f

Please sign in to comment.