Ejemplo n.º 1
0
static void sanity_checks(unsigned int check)
{
	if (check >= NUM_TEST_TYPES) {
		CTEST_LOG("WARNING: argument check out of bounds");
		ASSERT_FAIL();
	}
}
static void check_strategy(instruments_strategy_t correct_strategy,
                           instruments_strategy_t chosen_strategy,
                           enum EvalMethod method, 
                           char *msg)
{
    if (correct_strategy != chosen_strategy) {
        char buf[4096];
        snprintf(buf, 4096, "[%s] %s (expected %s, chose %s)", 
                 get_method_name(method), msg, 
                 get_strategy_name(correct_strategy),
                 get_strategy_name(chosen_strategy));
        CTEST_LOG(buf);
    }
    ASSERT_EQUAL((int)correct_strategy, (int) chosen_strategy);
}
Ejemplo n.º 3
0
CTEST2(nosetup, test1) {
    (void)data;
    CTEST_LOG("%s()", __func__);
}
Ejemplo n.º 4
0
CTEST2(weaklinkage, test2) {
    (void)data;
    CTEST_LOG("%s()", __func__);
}
Ejemplo n.º 5
0
CTEST2(memtest, test2) {
    CTEST_LOG("%s()  data=%p  buffer=%p", __func__, (void*)data, (void*)data->buffer);
    ASSERT_FAIL();
}
Ejemplo n.º 6
0
// These tests are called with the struct* (named data) as argument
CTEST2(memtest, test1) {
    CTEST_LOG("%s()  data=%p  buffer=%p", __func__, (void*)data, (void*)data->buffer);
}
Ejemplo n.º 7
0
CTEST2(nosetup, test1) {
    CTEST_LOG("%s()", __func__);
}
Ejemplo n.º 8
0
CTEST2(weaklinkage, test2) {
    CTEST_LOG("%s()", __func__);
}