Class RoundTest

java.lang.Object
com.singularsys.jeptests.unit.functions.RoundTest

public class RoundTest extends Object
Test rounding using various functions.
  • Constructor Details

    • RoundTest

      public RoundTest()
  • Method Details

    • roundingTest

      public void roundingTest(Round roundPFMC)
      Tests using the Math.round convention tie-breaks round to +ve infinity Since Jep 4.1 includes test for round(100000,-5) which used to give 99999.99999999999.
      Parameters:
      roundPFMC -
    • roundingTestHalfEven

      public void roundingTestHalfEven(Round roundPFMC)
      tie-breaks round to even value
      Parameters:
      roundPFMC -
    • problemsTest

      public void problemsTest(Round roundPFMC)
      Test for the problematic value 265.335. Multiplying by 100 gives 26533.499999999996 which rounds down.
      Parameters:
      roundPFMC -
    • testRounding

      @Test public void testRounding()
    • testRoundBD

      @Test public void testRoundBD()
    • testBDRound

      @Test public void testBDRound()
    • testRoundBDhalfEven

      @Test public void testRoundBDhalfEven()
    • testRint

      @Test public void testRint()