mirror of
https://github.com/yuzu-emu/unicorn
synced 2024-11-24 19:08:23 +00:00
35 lines
609 B
C
35 lines
609 B
C
#include "unicorn_test.h"
|
|
#include <stdio.h>
|
|
|
|
static int setup(void **state)
|
|
{
|
|
fprintf(stderr, "~~~ setup() ~~~\n");
|
|
|
|
uc_engine *uc;
|
|
|
|
uc_assert_success(uc_open(UC_ARCH_X86, UC_MODE_32, &uc));
|
|
|
|
*state = uc;
|
|
return 0;
|
|
}
|
|
|
|
static int teardown(void **state)
|
|
{
|
|
uc_engine *uc = *state;
|
|
fprintf(stderr, "~~~ teardown() ~~~\n");
|
|
|
|
uc_assert_success(uc_close(uc));
|
|
return 0;
|
|
}
|
|
|
|
|
|
static void test_basic(void **state)
|
|
{
|
|
}
|
|
|
|
int main(void) {
|
|
const struct CMUnitTest tests[] = {
|
|
cmocka_unit_test(test_basic),
|
|
};
|
|
return cmocka_run_group_tests(tests, setup, teardown);
|
|
}
|