X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=rt%2Ft%2Fapi%2Ftickets.t;h=50d08f756be2c47d76ee8ea89d2686d5c9e5ba75;hb=1f1c0ad8798bfaea287c47565f1a565ee7d82e5c;hp=cabb00e502748ed267168a37f2c7ed73c9ad2c11;hpb=6587f6ba7d047ddc1686c080090afe7d53365bd4;p=freeside.git diff --git a/rt/t/api/tickets.t b/rt/t/api/tickets.t index cabb00e50..50d08f756 100644 --- a/rt/t/api/tickets.t +++ b/rt/t/api/tickets.t @@ -2,7 +2,7 @@ use strict; use warnings; use RT; -use RT::Test tests => 16; +use RT::Test tests => 18; { @@ -101,3 +101,16 @@ ok( $unlimittickets->Count > 0, "UnLimited tickets object should return tickets" } + +{ + my $tickets = RT::Tickets->new( RT->SystemUser ); + $tickets->Limit( FIELD => 'id', OPERATOR => '>', VALUE => 0 ); + my $count = $tickets->Count(); + ok $count > 1, "found more than one ticket"; + undef $count; + + $tickets->Limit( FIELD => 'id', OPERATOR => '=', VALUE => 1, ENTRYAGGREGATOR => 'none' ); + $count = $tickets->Count(); + ok $count == 1, "found one ticket"; +} +