def METHOD_NAME(self, service_name, interaction_name, times=None):
    interactions = self.get_interactions_for_service(service_name)
    num_calls = interactions.get(interaction_name, {}).get('num_calls', 0)
    if times is None and not num_calls:
        raise AssertionError(
            'Interaction %s in %s was not used' % (interaction_name, service_name)
        )
    if times is not None and num_calls != times:
        raise AssertionError(
            'Interaction %s in %s wasn\'t used %d times (but %d times instead)'
            % (interaction_name, service_name, times, num_calls)
        )