tests: run tests on windows

This commit is contained in:
Recep Aslantas
2019-09-13 09:40:18 +03:00
parent 80c2b3712d
commit 5aa047efdf
8 changed files with 50 additions and 31 deletions

View File

@@ -78,4 +78,14 @@ typedef struct test_entry_t {
test_status_t test_ ## FUN (void); \
test_status_t test_ ## FUN()
#if defined(_WIN32)
# define srand48(x) srand((int)(x))
# define drand48() ((float)(rand() / RAND_MAX))
# define OK_TEXT "ok:"
# define FAIL_TEXT "fail:"
#else
# define OK_TEXT "✔︎"
# define FAIL_TEXT "𐄂"
#endif
#endif /* common_h */