Skip to content

Commit

Permalink
Update boost_matheval; add another testcase
Browse files Browse the repository at this point in the history
  • Loading branch information
hmenke committed Nov 28, 2017
1 parent 291f4a5 commit d035ea9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion libs/boost_matheval
7 changes: 7 additions & 0 deletions src/core/unit_tests/ExpressionParser_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,10 @@ BOOST_AUTO_TEST_CASE(integration3) {
// Evaluating should fail
BOOST_CHECK_THROW(parser.evaluate({}), std::invalid_argument);
}

BOOST_AUTO_TEST_CASE(integration4) {
Utils::ExpressionParser parser;

// Missing expression evaluates to zero
BOOST_CHECK_EQUAL(parser.evaluate({}), 0);
}

0 comments on commit d035ea9

Please sign in to comment.