60 FAIL_UNLESS(orc != NULL,
"Couldn't create first orc!");
86 FAIL_UNLESS(
result && strcmp(
result,
"name Orc chief\nWis 59\nhp 50\nexpmul 8.500000\ndam 168\nspeed 0.500000\n") == 0,
"2n diff modified obj/clone was %s!",
result);
102 snprintf(expect,
sizeof(expect),
"arch empty_archetype\nend\n");
114 FAIL_UNLESS(
empty->head != NULL,
"Couldn't create empty archetype as head!");
116 FAIL_UNLESS(
empty->more != NULL,
"Couldn't create empty archetype as more!");
119 snprintf(expect,
sizeof(expect),
"arch empty_archetype\nmore %d\nhead %d\nenv %d\ninv %d\nend\n",
empty->more->count,
empty->head->count,
empty->env->count,
empty->inv->count);
129 Suite *s = suite_create(
"loader");
130 TCase *tc_core = tcase_create(
"Core");
131 tcase_set_timeout(tc_core, 60);
136 suite_add_tcase(s, tc_core);
137 tcase_add_test(tc_core, test_get_ob_diff);
138 tcase_add_test(tc_core, test_object_dump);
146 SRunner *sr = srunner_create(s);
148 srunner_set_xml(sr, LOGDIR
"/unit/common/loader.xml");
149 srunner_set_log(sr, LOGDIR
"/unit/common/loader.out");
150 srunner_run_all(sr, CK_ENV);
151 nf = srunner_ntests_failed(sr);
153 return (nf == 0) ? EXIT_SUCCESS : EXIT_FAILURE;