Упрощение тестов
This commit is contained in:
parent
fcf793c758
commit
7f242c4b63
71 changed files with 518 additions and 943 deletions
|
|
@ -22,7 +22,7 @@ static const BgcQuaternionFP32 _TEST_FP32_QUATERNION_LIST2[] = {
|
|||
{ 1000.0f, -0.00025f, -0.419f, 0.844f }
|
||||
};
|
||||
|
||||
int test_quaternion_swap_fp32()
|
||||
void test_quaternion_swap_fp32()
|
||||
{
|
||||
BgcQuaternionFP32 quaternion1, quaternion2;
|
||||
|
||||
|
|
@ -43,13 +43,11 @@ int test_quaternion_swap_fp32()
|
|||
quaternion2.x2 != _TEST_FP32_QUATERNION_LIST1[i].x2 ||
|
||||
quaternion2.x3 != _TEST_FP32_QUATERNION_LIST1[i].x3) {
|
||||
print_testing_failed();
|
||||
return TEST_FAILED;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
print_testing_success();
|
||||
|
||||
return TEST_SUCCESS;
|
||||
}
|
||||
|
||||
// ==================== FP64 ==================== //
|
||||
|
|
@ -70,7 +68,7 @@ static const BgcQuaternionFP64 _TEST_FP64_QUATERNION_LIST2[] = {
|
|||
{ 1000.0, -0.00025, -0.419, 0.844 }
|
||||
};
|
||||
|
||||
int test_quaternion_swap_fp64()
|
||||
void test_quaternion_swap_fp64()
|
||||
{
|
||||
BgcQuaternionFP64 quaternion1, quaternion2;
|
||||
|
||||
|
|
@ -91,24 +89,15 @@ int test_quaternion_swap_fp64()
|
|||
quaternion2.x2 != _TEST_FP64_QUATERNION_LIST1[i].x2 ||
|
||||
quaternion2.x3 != _TEST_FP64_QUATERNION_LIST1[i].x3) {
|
||||
print_testing_failed();
|
||||
return TEST_FAILED;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
print_testing_success();
|
||||
|
||||
return TEST_SUCCESS;
|
||||
}
|
||||
|
||||
int test_quaternion_swap()
|
||||
void test_quaternion_swap()
|
||||
{
|
||||
if (test_quaternion_swap_fp32() != TEST_SUCCESS) {
|
||||
return TEST_FAILED;
|
||||
}
|
||||
|
||||
if (test_quaternion_swap_fp64() != TEST_SUCCESS) {
|
||||
return TEST_FAILED;
|
||||
}
|
||||
|
||||
return TEST_SUCCESS;
|
||||
test_quaternion_swap_fp32();
|
||||
test_quaternion_swap_fp64();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue