1use strict;
2use warnings;
3
4use Test::More tests => 4;
5BEGIN { require "t/utils.pl" };
6
7use_ok 'Parse::BooleanLogic';
8
9my $parser = Parse::BooleanLogic->new( operators => ['', 'OR'] );
10
11parse_cmp
12    $parser,
13    'x y',
14    [ { operand => 'x' }, '', { operand => 'y' } ],
15;
16
17parse_cmp
18    $parser,
19    'test from:me subject:"like this"',
20    [ { operand => 'test' }, '', { operand => 'from:me' }, '', { operand => 'subject:"like this"' } ],
21;
22
23parse_cmp
24    $parser,
25    'test (from:me OR to:me)',
26    [ { operand => 'test' }, '', [{ operand => 'from:me' }, 'OR', { operand => 'to:me' }] ],
27;
28
29