int main(int argc, const char **argv) { #ifdef _WIN32 WORD wVersionRequested; WSADATA wsaData; wVersionRequested = MAKEWORD(2, 2); (void) WSAStartup(wVersionRequested, &wsaData); #endif #ifndef _WIN32 if (signal(SIGPIPE, SIG_IGN) == SIG_ERR) return 1; #endif #ifdef _WIN32 tinytest_skip(testgroups, "http/connection_retry"); tinytest_skip(testgroups, "http/https_connection_retry"); #endif #ifndef EVENT__DISABLE_THREAD_SUPPORT if (!getenv("EVENT_NO_DEBUG_LOCKS")) evthread_enable_lock_debugging(); #endif if (getenv("EVENT_DEBUG_MODE")) { event_enable_debug_mode(); libevent_tests_running_in_debug_mode = 1; } if (getenv("EVENT_DEBUG_LOGGING_ALL")) { event_enable_debug_logging(EVENT_DBG_ALL); } tinytest_set_aliases(testaliases); evutil_weakrand_seed_(&test_weakrand_state, 0); if (tinytest_main(argc,argv,testgroups)) return 1; libevent_global_shutdown(); return 0; }
int main(int c, const char **v) { /* Finally, just call tinytest_main(). It lets you specify verbose or quiet output with --verbose and --quiet. You can list specific tests: tinytest-demo demo/memcpy or use a ..-wildcard to select multiple tests with a common prefix: tinytest-demo demo/.. If you list no tests, you get them all by default, so that "tinytest-demo" and "tinytest-demo .." mean the same thing. */ tinytest_set_aliases(aliases); return tinytest_main(c, v, groups); }