DUK_INTERNAL duk_uint_t duk_selftest_run_tests(duk_alloc_function alloc_func, duk_realloc_function realloc_func, duk_free_function free_func, void *udata) { duk_uint_t error_count = 0; DUK_D(DUK_DPRINT("self test starting")); error_count += duk__selftest_types(); error_count += duk__selftest_packed_tval(); error_count += duk__selftest_twos_complement(); error_count += duk__selftest_byte_order(); error_count += duk__selftest_bswap_macros(); error_count += duk__selftest_double_union_size(); error_count += duk__selftest_double_aliasing(); error_count += duk__selftest_double_zero_sign(); error_count += duk__selftest_double_rounding(); error_count += duk__selftest_struct_align(); error_count += duk__selftest_64bit_arithmetic(); error_count += duk__selftest_cast_double_to_small_uint(); error_count += duk__selftest_cast_double_to_uint32(); error_count += duk__selftest_alloc_funcs(alloc_func, realloc_func, free_func, udata); DUK_D(DUK_DPRINT("self test complete, total error count: %ld", (long) error_count)); return error_count; }
DUK_INTERNAL void duk_selftest_run_tests(void) { duk__selftest_types(); duk__selftest_packed_tval(); duk__selftest_twos_complement(); duk__selftest_byte_order(); duk__selftest_bswap_macros(); duk__selftest_double_union_size(); duk__selftest_double_aliasing(); duk__selftest_double_zero_sign(); duk__selftest_struct_align(); duk__selftest_64bit_arithmetic(); duk__selftest_cast_double_to_uint(); }