CAL-861 unit tests for invitations of rest-api