12#ifndef MCRL2_UTILITIES_DETAIL_TEST_OPERATION_H
13#define MCRL2_UTILITIES_DETAIL_TEST_OPERATION_H
35template <
typename Parser,
typename Operation1,
typename Operation2,
typename Compare>
37 const std::string& expr1,
38 const std::string& expr2,
42 const std::string& opname1,
44 const std::string& opname2
47 auto x1 = parse(expr1);
48 auto x2 = parse(expr2);
51 bool success = comp(f1, f2);
54 std::cout <<
"--- TEST SUCCEEDED --- " << std::endl;
58 std::cout <<
"--- TEST FAILED --- " << std::endl;
60 std::cout <<
"x" <<
" = " << x1 << std::endl;
61 std::cout <<
"y" <<
" = " << x2 << std::endl;
64 std::cout << (opname1 +
"(x)") <<
" = " << f1 << std::endl;
68 std::cout << (opname2 +
"(y)") <<
" = " << f2 << std::endl;
75template <
typename Parser,
typename Operation,
typename Compare>
77 const std::string& expr1,
78 const std::string& expr2,
82 const std::string& opname
85 return test_operation(expr1, expr2, parse, comp, op, opname, [](
const auto& T) {
return T; },
"");
bool test_operation(const std::string &expr1, const std::string &expr2, Parser parse, Compare comp, Operation1 op1, const std::string &opname1, Operation2 op2, const std::string &opname2)
Generic function that applies two operations to two objects, and compares the results.
A class that takes a linear process specification and checks all tau-summands of that LPS for conflue...