Class RpTest


public class RpTest extends JepTest
Tests the fastreal evaluator. @link{#testRpEval()} tests using the faster RpEval.evaluate method. Most other tests use the RpEvaluator which uses the jep evaluation framework and override tests from JepTest.
Author:
Richard Morris
  • Field Details

  • Constructor Details

    • RpTest

      public RpTest()
  • Method Details

    • setUp

      @BeforeEach public void setUp()
      Description copied from class: JepTest
      Sets up the parser.
      Overrides:
      setUp in class JepTest
    • valueTest

      protected void valueTest(String expr, Object expected) throws JepException
      Description copied from class: JepTest
      Test result j.evaluate(j.parse(expr))
      Overrides:
      valueTest in class JepTest
      Parameters:
      expr - the expression to parse and evaluate
      expected - result expected
      Throws:
      JepException
    • testRpEval

      @Test public void testRpEval() throws Exception
      Tests basic operation of the RpEval class.
      Throws:
      Exception
    • testRpSurf

      @Test public void testRpSurf() throws Exception
      Throws:
      Exception
    • testSetAllowUndeclared

      @Test public void testSetAllowUndeclared() throws Exception
      Description copied from class: JepTest
      Tests whether allowUndeclared is working properly.
      Overrides:
      testSetAllowUndeclared in class JepTest
      Throws:
      Exception
    • testChangeName

      @Test public void testChangeName() throws Exception
      Throws:
      Exception
    • testEvaluateComplex

      @Disabled("Complex test not relevant for Rp") @Test public void testEvaluateComplex()
      Overrides:
      testEvaluateComplex in class JepTest
    • testEvaluateString

      @Disabled("String test not relevant for Rp") @Test public void testEvaluateString()
      Overrides:
      testEvaluateString in class JepTest
    • testChangeVariableComplex

      @Disabled("Complex test not relevant for Rp") @Test public void testChangeVariableComplex()
      Description copied from class: JepTest
      Test changing variables value after parsing
      Overrides:
      testChangeVariableComplex in class JepTest
    • testStrings

      @Disabled("String test not relevant for Rp") @Test public void testStrings()
      Overrides:
      testStrings in class JepTest
    • testComplex

      @Disabled("Complex test not relevant for Rp") @Test public void testComplex()
      Overrides:
      testComplex in class JepTest
    • testListAccess

      @Disabled("List test not relevant for Rp") @Test public void testListAccess()
      Overrides:
      testListAccess in class JepTest
    • testListOperations

      @Disabled("List test not relevant for Rp") @Test public void testListOperations()
      Overrides:
      testListOperations in class JepTest
    • testComplexListAccess

      @Disabled("Complex test not relevant for Rp") @Test public void testComplexListAccess()
      Overrides:
      testComplexListAccess in class JepTest
    • testListAccessShiftZero

      @Disabled("List test not relevant for Rp") @Test public void testListAccessShiftZero()
      Overrides:
      testListAccessShiftZero in class JepTest
    • testListExtra

      @Disabled("List test not relevant for Rp") @Test public void testListExtra()
      Overrides:
      testListExtra in class JepTest
    • testListFunctions

      @Disabled("List test not relevant for Rp") @Test public void testListFunctions()
      Overrides:
      testListFunctions in class JepTest
    • testMultiDimArray

      @Disabled("Array tests not relevant for Rp") @Test public void testMultiDimArray()
      Overrides:
      testMultiDimArray in class JepTest
    • testMultiDimArrayShiftZero

      @Disabled("Array tests not relevant for Rp") @Test public void testMultiDimArrayShiftZero()
      Overrides:
      testMultiDimArrayShiftZero in class JepTest
    • testLazyLogicalBug

      @Disabled("Logical tests not relevant for Rp") @Test public void testLazyLogicalBug()
      Description copied from class: JepTest
      Test for bug with 1&&1&&1
      Overrides:
      testLazyLogicalBug in class JepTest
    • testLazyLogical

      @Disabled("Logical tests not relevant for Rp") @Test public void testLazyLogical()
      Overrides:
      testLazyLogical in class JepTest
    • testLazyLogical2

      @Disabled("Logic test not relevant for Rp") @Test public void testLazyLogical2()
      Overrides:
      testLazyLogical2 in class JepTest
    • testRecursiveMacroFunction

      @Disabled("RpEval cannot work with recursive functions") @Test public void testRecursiveMacroFunction()
      Overrides:
      testRecursiveMacroFunction in class JepTest
    • testCaseString

      @Disabled("String tests not relevant for Rp") @Test public void testCaseString()
      Overrides:
      testCaseString in class JepTest
    • testSwitch

      @Disabled("Switch test not relevant for Rp") @Test public void testSwitch()
      Overrides:
      testSwitch in class JepTest
    • testCaseNull

      @Disabled("Switch test not relevant for Rp") @Test public void testCaseNull()
      Overrides:
      testCaseNull in class JepTest
    • testNull

      @Disabled("Null test not relevant for Rp") @Test public void testNull()
      Overrides:
      testNull in class JepTest
    • testStringsFun

      @Disabled("String test not relevant for Rp") @Test public void testStringsFun()
      Overrides:
      testStringsFun in class JepTest
    • testSpecialFunctions

      public void testSpecialFunctions() throws Exception
      Overrides:
      testSpecialFunctions in class JepTest
      Throws:
      Exception
    • test_lightWeightInstance

      @Test public void test_lightWeightInstance() throws JepException
      Throws:
      JepException
    • test_lightWeightInstance_Jep

      @Test public void test_lightWeightInstance_Jep() throws JepException
      Throws:
      JepException
    • test_customFun_lightWeightInstance

      @Test public void test_customFun_lightWeightInstance() throws JepException
      Throws:
      JepException
    • test_customFun_lightWeightInstance_jep

      @Test public void test_customFun_lightWeightInstance_jep() throws JepException
      Throws:
      JepException
    • test_renamed_functions

      @Test public void test_renamed_functions() throws JepException
      Checks if a function renamed in jep works with ReEval instances.
      Throws:
      ParseException
      JepException
    • testChangeVariable

      @Disabled public void testChangeVariable() throws Exception
      Description copied from class: JepTest
      Test changing variables value after parsing
      Overrides:
      testChangeVariable in class JepTest
      Throws:
      Exception
    • testNaN

      @Disabled public void testNaN() throws Exception
      Overrides:
      testNaN in class JepTest
      Throws:
      Exception