-
Notifications
You must be signed in to change notification settings - Fork 217
Open
Description
From exception, BinomialBoundsN is expect to not take the 0 theta.(To prevent "divide 0" happend).
datasketches-java/src/main/java/org/apache/datasketches/thetacommon/BinomialBoundsN.java
Line 276 in b1d07af
| throw new SketchesArgumentException("0.0 < theta <= 1.0: " + theta); |
Following test is fail to check this because this test will pass if any checkArgs throw exception.
@Test
public static void checkCheckArgs() {
try {
checkArgs(-1L, 1.0, 1);
checkArgs(10L, 0.0, 1);
checkArgs(10L, 1.01, 1);
checkArgs(10L, 1.0, 3);
checkArgs(10L, 1.0, 0);
checkArgs(10L, 1.0, 4);
fail("Expected SketchesArgumentException");
} catch (final SketchesArgumentException e) {
//pass
}
}
Metadata
Metadata
Assignees
Labels
No labels