2
* Drizzle Client & Protocol Library
4
* Copyright (C) 2008 Eric Day (eday@oddments.org)
7
* Use and distribution licensed under the BSD license. See
8
* the COPYING file in this directory for full text.
13
* @brief drizzle_result_st tests
22
drizzle_result_st *result;
23
drizzle_result_st result_buffer;
24
drizzle_result_st *clone;
26
printf("sizeof(drizzle_result_st) = %zu\n", sizeof(drizzle_result_st));
28
if ((drizzle= drizzle_create(NULL)) == NULL)
29
drizzle_test_error("drizzle_create");
31
if ((con= drizzle_con_create(drizzle, NULL)) == NULL)
32
drizzle_test_error("drizzle_con_create");
34
if ((result= drizzle_result_create(con, &result_buffer)) == NULL)
35
drizzle_test_error("drizzle_result_create");
36
drizzle_result_free(result);
38
if ((result= drizzle_result_create(con, NULL)) == NULL)
39
drizzle_test_error("drizzle_result_create");
41
if ((clone= drizzle_result_clone(con, NULL, result)) == NULL)
42
drizzle_test_error("drizzle_result_clone");
43
drizzle_result_free(clone);
45
drizzle_result_set_info(result, "simple test");
47
if (strcmp(drizzle_result_info(result), "simple test"))
48
drizzle_test_error("drizzle_result_info");
50
drizzle_result_free(result);
51
drizzle_con_free(con);
52
drizzle_free(drizzle);