@Test public void testRecalculateLayer() { int length = EXPECTED_SES.length; assertEquals(length, ses.getLength()); assertEquals(Double.NaN, ses.getValue(-1), TestConfig.EPSILON); for (int d = 0; d < length; d++) assertEquals(EXPECTED_SES[d], ses.getValue(d), TestConfig.EPSILON); assertEquals(Double.NaN, ses.getValue(length), TestConfig.EPSILON); }
@Test public void testSetDefaultMethod() { assertTrue(ses.getDefaultMethod() instanceof DefaultLinkRatioSEFunction); ses.setDefaultMethod(new UserInputLinkRatioSEFunction()); assertTrue(ses.getDefaultMethod() instanceof UserInputLinkRatioSEFunction); ses.setDefaultMethod(null); assertTrue(ses.getDefaultMethod() instanceof DefaultLinkRatioSEFunction); }