From: Peter Rabbitson Date: Thu, 27 Aug 2009 22:11:29 +0000 (+0000) Subject: Add a test proving how dumb I am X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=f21e372a57c5e8481bd37c6f791b9123fab1b1c0;p=dbsrgits%2FDBIx-Class-Historic.git Add a test proving how dumb I am --- diff --git a/t/search/subquery.t b/t/search/subquery.t index 72eaeec..1f72b07 100644 --- a/t/search/subquery.t +++ b/t/search/subquery.t @@ -19,6 +19,17 @@ my $cdrs = $schema->resultset('CD'); my @tests = ( { rs => $cdrs, + search => \[ "title = ? AND year LIKE ?", 'buahaha', '20%' ], + attrs => { rows => 5 }, + sqlbind => \[ + "( SELECT me.cdid,me.artist,me.title,me.year,me.genreid,me.single_track FROM cd me WHERE (title = ? AND year LIKE ?) LIMIT 5)", + 'buahaha', + '20%', + ], + }, + + { + rs => $cdrs, search => { artist_id => { 'in' => $art_rs->search({}, { rows => 1 })->get_column( 'id' )->as_query }, },