19 #define SCHEMA_PREFIX PCMK__TEST_SCHEMA_DIR "/find_x_0/pacemaker-" 25 setenv(
"PCMK_schema_directory", PCMK__TEST_SCHEMA_DIR
"/find_x_0", 1);
30 teardown(
void **state)
32 unsetenv(
"PCMK_schema_directory");
37 assert_schema_0(
int schema_index,
const char *schema_name)
43 assert_non_null(entry);
46 assert_non_null(schema);
49 assert_string_equal(schema->
name, schema_name);
53 last_is_0(
void **state)
59 assert_schema_0(14,
"pacemaker-3.0");
64 last_is_not_0(
void **state)
72 assert_schema_0(3,
"pacemaker-2.0");
79 schema_0_missing(
void **state)
89 assert_schema_0(3,
"pacemaker-2.1");
98 cmocka_unit_test(last_is_0),
99 cmocka_unit_test(last_is_not_0),
100 cmocka_unit_test(schema_0_missing))
#define PCMK__UNIT_TEST(group_setup, group_teardown,...)
void crm_schema_init(void)
void crm_schema_cleanup(void)
G_GNUC_INTERNAL GList * pcmk__find_x_0_schema(void)