예제 #1
0
파일: dec64_test.c 프로젝트: kmsquire/DEC64
void test_round(dec64 first, dec64 second, dec64 expected, char * comment) {
    dec64 actual = dec64_round(first, second);
    judge_binary(first, second, expected, actual, "round", "r", comment);
}
예제 #2
0
파일: dec64_test.c 프로젝트: kmsquire/DEC64
void test_subtract(dec64 first, dec64 second, dec64 expected, char * comment) {
    dec64 actual = dec64_subtract(first, second);
    judge_binary(first, second, expected, actual, "subtract", "-", comment);
}
예제 #3
0
파일: dec64_test.c 프로젝트: kmsquire/DEC64
void test_modulo(dec64 first, dec64 second, dec64 expected, char * comment) {
    dec64 actual = dec64_modulo(first, second);
    judge_binary(first, second, expected, actual, "modulo", "%", comment);
}
예제 #4
0
파일: dec64_test.c 프로젝트: kmsquire/DEC64
void test_less(dec64 first, dec64 second, dec64 expected, char * comment) {
    dec64 actual = dec64_less(first, second);
    judge_binary(first, second, expected, actual, "less", "<", comment);
}
예제 #5
0
파일: dec64_test.c 프로젝트: kmsquire/DEC64
void test_integer_divide(dec64 first, dec64 second, dec64 expected, char * comment) {
    dec64 actual = dec64_integer_divide(first, second);
    judge_binary(first, second, expected, actual, "integer_divide", "/", comment);
}
예제 #6
0
파일: dec64_test.c 프로젝트: kmsquire/DEC64
void judge_communitive(dec64 first, dec64 second, dec64 expected, dec64 actual, char * name, char * op, char * comment) {
    judge_binary(first, second, expected, actual, name, op, comment);
    if (first != second) {
        judge_binary(second, first, expected, actual, name, op, comment);
    }
}
예제 #7
0
static void test_root(dec64 first, dec64 second, dec64 expected, char * comment) {
    dec64 actual = dec64_root(first, second);
    judge_binary(first, second, expected, actual, "root", "|", comment);
}