Commit 6690bce1 authored by niklas.baumgarten's avatar niklas.baumgarten
Browse files

New test case

parent b67bed4a
......@@ -70,7 +70,14 @@ TEST_P(TestClenshawCurtis, TestSumOfWeights) {
double sum = 0.0;
for (auto &weight : generator.GetWeights())
sum += weight;
EXPECT_NEAR(sum, 2.0 * dimension, TEST_TOLERANCE);
EXPECT_NEAR(sum, generator.SumOfWeights(), TEST_TOLERANCE);
}
TEST_P(TestClenshawCurtis, TestSumOfDrawnWeights) {
double sum = 0.0;
for (int i = 0; i < generator.GetNumPoints(); i++)
sum += generator.SampleWeight(SampleID(0, i, false));
EXPECT_NEAR(sum, generator.SumOfWeights(), TEST_TOLERANCE);
}
int main(int argc, char **argv) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment