fix pedestal QA unit test (#70)

This commit is contained in:
Bechir Braham 2024-05-15 11:20:13 +02:00 committed by GitHub
parent 91a628cd6c
commit fed362e843
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -98,9 +98,9 @@ TEST_CASE("test pedestal with normal distribution") {
for (int i = 0; i < 4; i++) {
for (int j = 0; j < 4; j++) {
// 10% tolerance
compare_floats<double>(mean(i, j), MEAN, MEAN * TOLERANCE);
compare_floats<double>(variance(i, j), VAR, VAR * TOLERANCE);
compare_floats<double>(standard_deviation(i, j), STD, STD * TOLERANCE);
REQUIRE(compare_floats<double>(mean(i, j), MEAN, MEAN * TOLERANCE));
REQUIRE(compare_floats<double>(variance(i, j), VAR, VAR * TOLERANCE));
REQUIRE(compare_floats<double>(standard_deviation(i, j), STD, STD * TOLERANCE)); // maybe sqrt of tolerance?
}
}
}