lagopus_result_t
ofp_group_stats_reply_create_null_wrap(struct channel *channel,
                                       struct pbuf_list **pbuf_list,
                                       struct ofp_header *xid_header) {
  lagopus_result_t ret;
  struct group_stats_list group_stats_list;

  group_stats_num = 2;
  bucket_counter_num = 2;
  create_data(&group_stats_list);

  ret = ofp_group_stats_reply_create(NULL, pbuf_list,
                                     &group_stats_list,
                                     xid_header);
  TEST_ASSERT_EQUAL_MESSAGE(LAGOPUS_RESULT_INVALID_ARGS, ret,
                            "ofp_group_stats_reply_create error.");

  ret = ofp_group_stats_reply_create(channel, NULL,
                                     &group_stats_list,
                                     xid_header);
  TEST_ASSERT_EQUAL_MESSAGE(LAGOPUS_RESULT_INVALID_ARGS, ret,
                            "ofp_group_stats_reply_create error.");

  ret = ofp_group_stats_reply_create(channel, pbuf_list,
                                     NULL,
                                     xid_header);
  TEST_ASSERT_EQUAL_MESSAGE(LAGOPUS_RESULT_INVALID_ARGS, ret,
                            "ofp_group_stats_reply_create error.");

  ret = ofp_group_stats_reply_create(channel, pbuf_list,
                                     &group_stats_list,
                                     NULL);
  TEST_ASSERT_EQUAL_MESSAGE(LAGOPUS_RESULT_INVALID_ARGS, ret,
                            "ofp_group_stats_reply_create error.");

  /* after. */
  group_stats_list_elem_free(&group_stats_list);

  /* Not check return value. */
  return -9999;
}
lagopus_result_t
ofp_group_stats_reply_create_wrapwith_self_data(
  struct channel *channel,
  struct pbuf_list **pbuf_list,
  struct ofp_header *xid_header) {
  lagopus_result_t ret;

  ret = ofp_group_stats_reply_create(channel, pbuf_list,
                                     &gstats_list,
                                     xid_header);

  return ret;
}
lagopus_result_t
ofp_group_stats_reply_create_wrap(struct channel *channel,
                                  struct pbuf_list **pbuf_list,
                                  struct ofp_header *xid_header) {
  lagopus_result_t ret;

  create_data();

  ret = ofp_group_stats_reply_create(channel, pbuf_list,
                                     &gstats_list,
                                     xid_header);

  /* after. */
  group_stats_list_elem_free(&gstats_list);
  return ret;
}