7 #include "eobj_suite.h"
10 #include "class_simple.h"
12 START_TEST(eobj_simple)
15 Eobj *obj = eobj_add(EOBJ_CLASS_BASE, NULL);
22 START_TEST(eobj_op_errors)
25 Eobj *obj = eobj_add(SIMPLE_CLASS, NULL);
27 /* Out of bounds op for a legal class. */
28 fail_if(eobj_do(obj, 0x00010111));
31 fail_if(eobj_do(obj, 0x0F010111));
33 fail_if(eobj_ref_get(obj) != 1);
36 fail_if(eobj_ref_get(obj) != 2);
39 fail_if(eobj_ref_get(obj) != 3);
42 fail_if(eobj_ref_get(obj) != 2);
45 fail_if(eobj_ref_get(obj) != 1);
52 void eobj_test_general(TCase *tc)
54 tcase_add_test(tc, eobj_op_errors);
55 tcase_add_test(tc, eobj_simple);