static void test_bmln_master_info (BT_TEST_ARGS) { BT_TEST_START; GST_INFO ("-- arrange --"); bml_setup (); GST_INFO ("-- act --"); bmln_set_master_info (120, 4, 44100); BT_TEST_END; }
static void test_bml_setup (BT_TEST_ARGS) { BT_TEST_START; GST_INFO ("-- act --"); int res = bml_setup (); GST_INFO ("-- assert --"); fail_unless (res, NULL); BT_TEST_END; }
static void test_bml_finalize (BT_TEST_ARGS) { BT_TEST_START; GST_INFO ("-- arrange --"); bml_setup (); GST_INFO ("-- act --"); bml_finalize (); BT_TEST_END; }
int main (int argc, char **argv) { int okay = 0; setlinebuf (stdout); setlinebuf (stderr); puts ("main beg"); if (bml_setup ()) { char *lib_name; int sl, i; #ifdef USE_DLLWRAPPER /* FIXME: if people have no real win32 dlls, only emulated things, this will crash here */ bmlw_set_master_info (120, 4, 44100); #endif /* USE_DLLWRAPPER */ bmln_set_master_info (120, 4, 44100); puts ("master info initialized"); for (i = 1; i < argc; i++) { lib_name = argv[i]; sl = strlen (lib_name); if (sl > 4) { if (!strcasecmp (&lib_name[sl - 4], ".dll")) { #ifdef USE_DLLWRAPPER okay = bmlw_test_info (lib_name); #else puts ("no dll emulation on non x86 platforms"); #endif /* USE_DLLWRAPPER */ } else { okay = bmln_test_info (lib_name); } } } bml_finalize (); } puts ("main end"); return okay ? 0 : 1; }
int main (int argc, char **argv) { int okay = 0; setvbuf (stderr, NULL, _IOLBF, 0); puts ("main beg"); if (bml_setup ()) { char *lib_name; int sl; #ifdef USE_DLLWRAPPER bmlw_set_master_info (120, 4, 44100); #endif /* USE_DLLWRAPPER */ bmln_set_master_info (120, 4, 44100); puts (" master info initialized"); if (argc > 2) { lib_name = argv[1]; sl = strlen (lib_name); if (sl > 4) { if (!strcasecmp (&lib_name[sl - 4], ".dll")) { #ifdef USE_DLLWRAPPER okay = bmlw_test_process (lib_name, argv[2], argv[3]); #else puts ("no dll emulation on non x86 platforms"); #endif /* USE_DLLWRAPPER */ } else { okay = bmln_test_process (lib_name, argv[2], argv[3]); } } } else puts (" not enough args!"); bml_finalize (); } puts ("main end"); return okay ? 0 : 1; }