Skip to content

Request feature to verify mock is called by exact number of times and in certain sequence? #54

Description

@kungfucop

Hi, for function to test like following:

fn handle_response(response:Response) {
  save_db(response.get_users());
  let unread_count = read_unread_from_db();
  send_push_notification(unread_count);
}

I'd like to make sure send_push_notification did get called with the desired count in the unit test. How could I do this?

Thanks a lot!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions