Fixed placeholder parser tests.

This commit is contained in:
bubnikv 2017-12-21 17:27:24 +01:00
parent 1eef6d3552
commit 9d3ade81fa

View File

@ -87,8 +87,8 @@ use Slic3r::Test;
is $parser->evaluate_boolean_expression('(12 == 12) and not (13 == 14)'), 1, 'boolean expression parser: (12 == 12) and not (13 == 14)'; is $parser->evaluate_boolean_expression('(12 == 12) and not (13 == 14)'), 1, 'boolean expression parser: (12 == 12) and not (13 == 14)';
is $parser->evaluate_boolean_expression('(12 == 12) ? (1 - 1 == 0) : (2 * 2 == 3)'), 1, 'boolean expression parser: ternary true'; is $parser->evaluate_boolean_expression('(12 == 12) ? (1 - 1 == 0) : (2 * 2 == 3)'), 1, 'boolean expression parser: ternary true';
is $parser->evaluate_boolean_expression('(12 == 21/2) ? (1 - 1 == 0) : (2 * 2 == 3)'), 0, 'boolean expression parser: ternary false'; is $parser->evaluate_boolean_expression('(12 == 21/2) ? (1 - 1 == 0) : (2 * 2 == 3)'), 0, 'boolean expression parser: ternary false';
is $parser->evaluate_boolean_expression('(12 == 13) ? (1 - 1 == 3) : (2 * 2 == 4)"'), 1, 'boolean expression parser: ternary false'; is $parser->evaluate_boolean_expression('(12 == 13) ? (1 - 1 == 3) : (2 * 2 == 4)'), 1, 'boolean expression parser: ternary false';
is $parser->evaluate_boolean_expression('(12 == 2 * 6) ? (1 - 1 == 3) : (2 * 2 == 4)"'), 0, 'boolean expression parser: ternary true'; is $parser->evaluate_boolean_expression('(12 == 2 * 6) ? (1 - 1 == 3) : (2 * 2 == 4)'), 0, 'boolean expression parser: ternary true';
is $parser->evaluate_boolean_expression('12 < 3'), 0, 'boolean expression parser: lower than - false'; is $parser->evaluate_boolean_expression('12 < 3'), 0, 'boolean expression parser: lower than - false';
is $parser->evaluate_boolean_expression('12 < 22'), 1, 'boolean expression parser: lower than - true'; is $parser->evaluate_boolean_expression('12 < 22'), 1, 'boolean expression parser: lower than - true';
is $parser->evaluate_boolean_expression('12 > 3'), 1, 'boolean expression parser: lower than - true'; is $parser->evaluate_boolean_expression('12 > 3'), 1, 'boolean expression parser: lower than - true';