66 if (knows_dish ==
false) {
71 if (has_ingredients ==
false) {
76 *dish_out = strdup(dish);
77 if (*dish_out == NULL)
return ENOMEM;
93 fprintf(stderr,
"Chef couldn't cook %s: %s\n",
99 if (strcmp(order, *dish) != 0) {
#define cmocka_unit_test(f)
Initializes a CMUnitTest structure.
static int waiter_process(const char *order, char **dish)
int __wrap_chef_cook(const char *order, char **dish_out)
#define assert_string_equal(a, b)
int chef_cook(const char *order, char **dish_out)
#define will_return(function, value)
#define cast_ptr_to_largest_integral_type(value)
#define cmocka_run_group_tests(group_tests, group_setup, group_teardown)
static void test_order_hotdog(void **state)
#define mock_ptr_type(type)
const char * chef_strerror(int error)
#define check_expected_ptr(parameter)
#define expect_string(function, parameter, string)
#define assert_int_equal(a, b)
static void test_bad_dish(void **state)