test: make assert_return() critical by default on fuzzer and unit tests

Several test cases intentionally trigger assert_return(). So, to avoid
the entire test fails, this introduces several macros that tentatively
make assert_return() not critical.
This commit is contained in:
Yu Watanabe
2023-12-24 02:02:18 +09:00
parent 93bb67090c
commit 8161f6086e
16 changed files with 132 additions and 85 deletions
+1
View File
@@ -31,6 +31,7 @@ static inline bool outside_size_range(size_t size, size_t lower, size_t upper) {
static inline void fuzz_setup_logging(void) {
/* We don't want to fill the logs and slow down stuff when running
* in a fuzzing mode, so disable most of the logging. */
log_set_assert_return_is_critical(true);
log_set_max_level(LOG_CRIT);
log_parse_environment();
log_open();