Criterion/samples/timeout.c

13 lines
195 B
C
Raw Permalink Normal View History

2015-09-11 16:56:40 +02:00
#include <criterion/criterion.h>
#ifdef _WIN32
# include <windows.h>
2015-09-11 16:56:40 +02:00
# define sleep(x) Sleep(x * 1000)
#else
# include <unistd.h>
#endif
Test(timeout, simple, .timeout = 1.) {
sleep(10);
}