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
    • Constructor Detail

      • RpTest

        public RpTest()
    • Method Detail

      • setUp

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

        protected void valueTest​(java.lang.String expr,
                                 java.lang.Object expected)
                          throws java.lang.Exception
        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:
        java.lang.Exception
      • testRpEval

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

        public void testRpSurf()
                        throws java.lang.Exception
        Throws:
        java.lang.Exception
      • testSetAllowUndeclared

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

        public void testChangeName()
                            throws java.lang.Exception
        Throws:
        java.lang.Exception
      • testEvaluateComplex

        public void testEvaluateComplex()
                                 throws java.lang.Exception
        Overrides:
        testEvaluateComplex in class JepTest
        Throws:
        java.lang.Exception
      • testEvaluateString

        public void testEvaluateString()
                                throws java.lang.Exception
        Overrides:
        testEvaluateString in class JepTest
        Throws:
        java.lang.Exception
      • testChangeVariableComplex

        public void testChangeVariableComplex()
                                       throws java.lang.Exception
        Description copied from class: JepTest
        Test changing variables value after parsing
        Overrides:
        testChangeVariableComplex in class JepTest
        Throws:
        java.lang.Exception
      • testStrings

        public void testStrings()
                         throws java.lang.Exception
        Overrides:
        testStrings in class JepTest
        Throws:
        java.lang.Exception
      • testComplex

        public void testComplex()
                         throws java.lang.Exception
        Overrides:
        testComplex in class JepTest
        Throws:
        java.lang.Exception
      • testListAccess

        public void testListAccess()
                            throws java.lang.Exception
        Overrides:
        testListAccess in class JepTest
        Throws:
        java.lang.Exception
      • testComplexListAccess

        public void testComplexListAccess()
                                   throws java.lang.Exception
        Overrides:
        testComplexListAccess in class JepTest
        Throws:
        java.lang.Exception
      • testListAccessShiftZero

        public void testListAccessShiftZero()
                                     throws java.lang.Exception
        Overrides:
        testListAccessShiftZero in class JepTest
        Throws:
        java.lang.Exception
      • testListExtra

        public void testListExtra()
                           throws java.lang.Exception
        Overrides:
        testListExtra in class JepTest
        Throws:
        java.lang.Exception
      • testListFunctions

        public void testListFunctions()
                               throws java.lang.Exception
        Overrides:
        testListFunctions in class JepTest
        Throws:
        java.lang.Exception
      • testMultiDimArray

        public void testMultiDimArray()
                               throws java.lang.Exception
        Overrides:
        testMultiDimArray in class JepTest
        Throws:
        java.lang.Exception
      • testMultiDimArrayShiftZero

        public void testMultiDimArrayShiftZero()
                                        throws java.lang.Exception
        Overrides:
        testMultiDimArrayShiftZero in class JepTest
        Throws:
        java.lang.Exception
      • testLazyLogicalBug

        public void testLazyLogicalBug()
                                throws java.lang.Exception
        Description copied from class: JepTest
        Test for bug with 1&&1&&1
        Overrides:
        testLazyLogicalBug in class JepTest
        Throws:
        java.lang.Exception
      • testLazyLogical

        public void testLazyLogical()
                             throws java.lang.Exception
        Overrides:
        testLazyLogical in class JepTest
        Throws:
        java.lang.Exception
      • testLazyLogical2

        public void testLazyLogical2()
                              throws java.lang.Exception
        Overrides:
        testLazyLogical2 in class JepTest
        Throws:
        java.lang.Exception
      • testRecursiveMacroFunction

        public void testRecursiveMacroFunction()
                                        throws java.lang.Exception
        Overrides:
        testRecursiveMacroFunction in class JepTest
        Throws:
        java.lang.Exception
      • testCaseString

        public void testCaseString()
                            throws java.lang.Exception
        Overrides:
        testCaseString in class JepTest
        Throws:
        java.lang.Exception
      • testSwitch

        public void testSwitch()
                        throws java.lang.Exception
        Overrides:
        testSwitch in class JepTest
        Throws:
        java.lang.Exception
      • testCaseNull

        public void testCaseNull()
                          throws java.lang.Exception
        Overrides:
        testCaseNull in class JepTest
        Throws:
        java.lang.Exception
      • testNull

        public void testNull()
                      throws java.lang.Exception
        Overrides:
        testNull in class JepTest
        Throws:
        java.lang.Exception
      • testStringsFun

        public void testStringsFun()
                            throws java.lang.Exception
        Overrides:
        testStringsFun in class JepTest
        Throws:
        java.lang.Exception
      • testSpecialFunctions

        public void testSpecialFunctions()
                                  throws java.lang.Exception
        Overrides:
        testSpecialFunctions in class JepTest
        Throws:
        java.lang.Exception
      • test_customFun_lightWeightInstance

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

        public void test_customFun_lightWeightInstance_jep()
                                                    throws JepException
        Throws:
        JepException