mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-18 21:30:38 +01:00
[poincare] Store: add tests on composed functions
This commit is contained in:
@@ -199,6 +199,12 @@ QUIZ_CASE(poincare_store_composed_functions) {
|
||||
assert_parsed_expression_evaluates_to<double>("g(3)+[[1]]", "[[18]]");
|
||||
assert_parsed_expression_evaluates_to<double>("g(5)", "45");
|
||||
|
||||
// g: x->x+1
|
||||
assert_simplify("x+1>g(x)");
|
||||
assert_parsed_expression_evaluates_to<double>("f(g(4))", "25");
|
||||
// Add a matrix to bypass simplification
|
||||
assert_parsed_expression_evaluates_to<double>("f(g(4))+[[1]]", "[[26]]");
|
||||
|
||||
// Clean the storage for other tests
|
||||
Ion::Storage::sharedStorage()->recordNamed("f.func").destroy();
|
||||
Ion::Storage::sharedStorage()->recordNamed("g.func").destroy();
|
||||
|
||||
Reference in New Issue
Block a user