HomePhabricator
Diffusion Comm 125b7b3a97e6

[services] Tunnelbroker - Database findMessageItemsByReceiver tests

Description

[services] Tunnelbroker - Database findMessageItemsByReceiver tests

Summary:
Database (DynamoDB) findMessageItemsByReceiver function tests:

  • Check if the table is available,
  • Create and fulfill database MessageItem entity,
  • Put the item into the database table,
  • Find the records by the ToDeviceID field key using findMessageItemsByReceiver function (D3239),
  • Compare first record fields of created item and item from database record,
  • Remove the testing record from the database.

Test Plan: Run yarn test-tunnelbroker-service all tests are run and succeed.

Reviewers: karol-bisztyga, palys-swm

Reviewed By: palys-swm

Subscribers: ashoat, palys-swm, Adrian, atul, karol-bisztyga, benschac, yayabosh

Differential Revision: https://phabricator.ashoat.com/D3781

Details