def test_flatten_nested_expr_with_arrays(self): """Test flattened expressions with nested arrays""" flattened = ConditionalSimplifier.flatten_nested_expr( [['a', '&', 'b'], '&', 'c']) self.assertEqual('((a & b) & c)', flattened)
def test_flatten_nested_expr(self): """Test flattened expressions""" flattened = ConditionalSimplifier.flatten_nested_expr(['a', '&', 'b']) self.assertEqual('(a & b)', flattened)