You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
miniaudio/tests/test_automated/ma_test_automated.c

34 lines
871 B
C

#include "../test_common/ma_test_common.c"
#include "ma_test_automated_data_converter.c"
int main(int argc, char** argv)
{
ma_result result;
ma_bool32 hasError = MA_FALSE;
size_t iTest;
(void)argc;
(void)argv;
result = ma_register_test("Data Conversion", test_entry__data_converter);
if (result != MA_SUCCESS) {
return result;
}
for (iTest = 0; iTest < g_Tests.count; iTest += 1) {
printf("=== BEGIN %s ===\n", g_Tests.pTests[iTest].pName);
result = g_Tests.pTests[iTest].onEntry(argc, argv);
printf("=== END %s : %s ===\n", g_Tests.pTests[iTest].pName, (result == 0) ? "PASSED" : "FAILED");
if (result != 0) {
hasError = MA_TRUE;
}
}
if (hasError) {
return -1; /* Something failed. */
} else {
return 0; /* Everything passed. */
}
}