diff --git a/include/core/random.h b/include/core/random.h index e332314a..573d3302 100644 --- a/include/core/random.h +++ b/include/core/random.h @@ -4,17 +4,17 @@ #ifndef OCARINA_CORE_RANDOM_H #define OCARINA_CORE_RANDOM_H -#ifndef CONFIG_TEST +#ifdef CONFIG_TEST + +void _seed_random(unsigned int); +unsigned int _pick_random(); + +#else /* CONFIG_TEST */ #include static inline void _seed_random(unsigned int n) { srand(time(NULL) + n); } static inline unsigned int _pick_random() { return rand(); } -#else /* CONFIG_TEST */ - -void _seed_random(unsigned int); -unsigned int _pick_random(); - #endif /* CONFIG_TEST */