Class BigDecimalTest

java.lang.Object
com.singularsys.jeptests.system.BigDecimalTest

public class BigDecimalTest extends Object
Tests the BigDecComponents through a set of test expressions that are evaluated.
Author:
singularsys
  • Constructor Details

    • BigDecimalTest

      public BigDecimalTest()
  • Method Details

    • unlimitedPrecisionTest

      public void unlimitedPrecisionTest()
    • cmpBug

      public void cmpBug()
      Check for problems where MinMax used comparisons which worked by first converting to doubles.
    • limitedPrecisionTest

      public void limitedPrecisionTest()
    • power_only_works_when_argument_is_integral

      public void power_only_works_when_argument_is_integral() throws JepException
      Trying to raise a big decimal to a non-integral big decimal fails as not supported by BigDecimal BigDecimal Rounding using power operator
      Throws:
      JepException
    • test

      public void test(String str, boolean value)
      Test expression against boolean
      Parameters:
      str -
      value -
    • test

      public void test(String str, String value)
    • eval

      public Object eval(String str)
    • testCP

      public void testCP() throws Exception
      Throws:
      Exception
    • exprEquals

      public void exprEquals(String expr, Object expected) throws JepException
      Throws:
      JepException
    • evalExceptionTest

      public void evalExceptionTest(String expr) throws JepException
      Throws:
      JepException
    • testSetAllowStrings

      public void testSetAllowStrings() throws Exception
      Throws:
      Exception
    • testBoolean

      public void testBoolean() throws Exception
      Throws:
      Exception
    • testBDString

      public void testBDString() throws Exception
      Tests inter-operability of big decimals and strings.
      Throws:
      Exception
    • Abs

      public void Abs()
    • Round

      public void Round()
    • Signum

      public void Signum()
    • MinMax

      public void MinMax()
    • Avg

      public void Avg()
    • testIf

      public void testIf()
    • testCoerce

      public void testCoerce() throws Exception
      Throws:
      Exception