Package com.singularsys.exttests
Class XJepTest
- java.lang.Object
-
- com.singularsys.jeptests.system.JepTest
-
- com.singularsys.exttests.XJepTest
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.singularsys.jeptests.system.JepTest
JepTest.AddFractionsNary, JepTest.AddFractionsStack, JepTest.Diff, JepTest.MyBinary, JepTest.MyNary, JepTest.MyNaryBinary, JepTest.MyNullary, JepTest.MyUnary, JepTest.PiFun, JepTest.Product, JepTest.Square
-
-
Constructor Summary
Constructors Constructor Description XJepTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidbuild_expression_step_by_step_using_preprocess_eval_and_eqn()voidcleanerTest(java.lang.String expr, java.lang.String expected)parses, processes and cleans both expression, tests toString are equalsvoideval_function_cause_argument_to_be_evaluated_at_preprocessed_time()NodeparseProcCleanEval(java.lang.String expr, java.lang.Object expected)Parse, process, clean and evaluated tests equal to expectedvoidpreprocess_function_cause_argument_to_be_preprocessed_at_eval_time()voidprocessCleanTestString(java.lang.String expr, java.lang.String expected)Parse, process, cleans expr test equal to expectedvoidrun_preprocessor_commands(XJep jep)voidsetUp()Sets up the parser.voidshallowcopy_of_preprocess_functions_are_new_instances_of_same_classes()voidtest_substitution_with_xvariable()voidtest_xassign_with_preprocessor()Three different cases: XAssign with use equation == false, do nothing use equation == true, var on lhs, set vars equation use equation == true, LValueI on lhs do nothing use equation == true, SymbolicLValueI on lhs, call setEqn() check preprocessing workvoidtestBad()voidtestBenstein()voidtestCleaner()voidtestExpand()voidtestFormat()voidtestFunctionTable()Checks it uses DirtyRandomvoidtestFunctionTableWithExtraComponents()voidtestLogical()voidtestNull()voidtestOperatorTable()voidtestPrint()voidtestReentrant()voidtestSetupPreprocess_functions_using_default_constructor()voidtestSetupPreprocess_functions_using_xjep_constructor()voidtestSub()voidtestTreeBuild()voidtestUndecVar()voidtestVariableReuse()voidtestVarInEqn()voidtestXFunctionTable_with_decorator_counstructor()-
Methods inherited from class com.singularsys.jeptests.system.JepTest
assertEqNodes, buildMatrix, buildVector, calcValue, calcValue, checkVector, compareRecursive, complexValueTest, myAssertEquals, myAssertNaN, myAssertNull, negativeZero, nodeTest, nodeTest, nodeTest, nodeTest, printTestHeader, setShiftZeroElePfmc, test_not_X_Y, testAssign, testBinom, testBlankParser, testCaseNull, testCaseString, testChangeVariable, testChangeVariableComplex, testComments, testComplex, testComplexListAccess, testEleUnit, testEmptyEqn, testEmptyEqn2, testEvalExceptions, testEvaluate, testEvaluateComplex, testEvaluateString, testExpectedTokenSequence, testFunction, testIf, testImplicitMul, testLazyLogical, testLazyLogical2, testLazyLogicalBug, testListAccess, testListAccessShiftZero, testListExtra, testListFunctions, testLogarithm, testMacroFunction, testMultiDimArray, testMultiDimArrayShiftZero, testMultiLine, testMultiplyBug, testNaN, testNoAssign, testNumberAsBooleanLogical, testNumbers, testNumParam, testParseException, testPlusPlus, testRecursiveMacroFunction, testSemiColon, testSetAllowUndeclared, testSimpleSum, testSpecialFunctions, testSpecialFunctions, testStrings, testStringsFun, testSwitch, testUminusPower, testX2Y, valueTest, valueTest, valueTestFail, valueTestNaN, valueTestNull, valueTestString
-
-
-
-
Field Detail
-
xj
protected XJep xj
-
-
Method Detail
-
setUp
public void setUp()
Description copied from class:JepTestSets up the parser.
-
testOperatorTable
public void testOperatorTable()
-
testFunctionTable
public void testFunctionTable()
Checks it uses DirtyRandom
-
testFunctionTableWithExtraComponents
public void testFunctionTableWithExtraComponents()
-
testXFunctionTable_with_decorator_counstructor
public void testXFunctionTable_with_decorator_counstructor()
-
processCleanTestString
public void processCleanTestString(java.lang.String expr, java.lang.String expected) throws JepExceptionParse, process, cleans expr test equal to expected- Parameters:
expr-expected-- Throws:
JepException
-
cleanerTest
public void cleanerTest(java.lang.String expr, java.lang.String expected) throws JepExceptionparses, processes and cleans both expression, tests toString are equals- Parameters:
expr-expected-- Throws:
JepException
-
parseProcCleanEval
public Node parseProcCleanEval(java.lang.String expr, java.lang.Object expected) throws ParseException, java.lang.Exception
Parse, process, clean and evaluated tests equal to expected- Parameters:
expr-expected-- Returns:
- Throws:
ParseExceptionjava.lang.Exception
-
testLogical
public void testLogical() throws java.lang.Exception- Overrides:
testLogicalin classJepTest- Throws:
java.lang.Exception
-
testPrint
public void testPrint() throws JepException- Throws:
JepException
-
testCleaner
public void testCleaner() throws JepException- Throws:
JepException
-
testExpand
public void testExpand() throws ParseException- Throws:
ParseException
-
testVariableReuse
public void testVariableReuse() throws java.lang.Exception- Throws:
java.lang.Exception
-
testReentrant
public void testReentrant() throws ParseException, java.lang.Exception- Throws:
ParseExceptionjava.lang.Exception
-
testFormat
public void testFormat() throws java.lang.Exception- Overrides:
testFormatin classJepTest- Throws:
java.lang.Exception
-
testVarInEqn
public void testVarInEqn() throws java.lang.Exception- Throws:
java.lang.Exception
-
testUndecVar
public void testUndecVar() throws JepException- Throws:
JepException
-
testTreeBuild
public void testTreeBuild() throws java.lang.Exception- Throws:
java.lang.Exception
-
testSub
public void testSub() throws java.lang.Exception- Throws:
java.lang.Exception
-
testNull
public void testNull() throws java.lang.Exception
-
testBad
public void testBad() throws java.lang.Exception- Throws:
java.lang.Exception
-
preprocess_function_cause_argument_to_be_preprocessed_at_eval_time
public void preprocess_function_cause_argument_to_be_preprocessed_at_eval_time() throws JepException- Throws:
JepException
-
eval_function_cause_argument_to_be_evaluated_at_preprocessed_time
public void eval_function_cause_argument_to_be_evaluated_at_preprocessed_time() throws JepException- Throws:
JepException
-
build_expression_step_by_step_using_preprocess_eval_and_eqn
public void build_expression_step_by_step_using_preprocess_eval_and_eqn() throws JepException- Throws:
JepException
-
run_preprocessor_commands
public void run_preprocessor_commands(XJep jep) throws JepException
- Throws:
JepException
-
testSetupPreprocess_functions_using_xjep_constructor
public void testSetupPreprocess_functions_using_xjep_constructor() throws JepException- Throws:
JepException
-
testSetupPreprocess_functions_using_default_constructor
public void testSetupPreprocess_functions_using_default_constructor() throws JepException- Throws:
JepException
-
shallowcopy_of_preprocess_functions_are_new_instances_of_same_classes
public void shallowcopy_of_preprocess_functions_are_new_instances_of_same_classes() throws JepException- Throws:
JepException
-
testBenstein
public void testBenstein() throws JepException- Throws:
JepException
-
test_substitution_with_xvariable
public void test_substitution_with_xvariable() throws JepException- Throws:
JepException
-
test_xassign_with_preprocessor
public void test_xassign_with_preprocessor() throws JepExceptionThree different cases:- XAssign with use equation == false, do nothing
- use equation == true, var on lhs, set vars equation
- use equation == true, LValueI on lhs do nothing
- use equation == true, SymbolicLValueI on lhs, call setEqn()
- Throws:
JepException
-
-