X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F05in_between.t;h=ff6b738dca4b32777d9d312af9055f13b5be44b9;hb=3a06278c0b7a87c5d3c64bdaa0ed0895f03133f2;hp=aa0b13a6afd6c7ff51346171b93c6d0bb81673ca;hpb=e41c3bdda9401514dcc02a3877346e4db953f41a;p=dbsrgits%2FSQL-Abstract.git diff --git a/t/05in_between.t b/t/05in_between.t index aa0b13a..ff6b738 100644 --- a/t/05in_between.t +++ b/t/05in_between.t @@ -101,20 +101,30 @@ my @in_between_tests = ( { parenthesis_significant => 1, where => { x => { -in => \'( 1,2,lower(y) )' } }, - stmt => "WHERE ( x IN (1, 2, lower(y) ) )", + stmt => "WHERE ( x IN ( 1,2,lower(y) ) )", bind => [], test => '-in with a literal scalarref', }, { parenthesis_significant => 1, where => { x => { -in => \['( ( ?,?,lower(y) ) )', 1, 2] } }, - stmt => "WHERE ( x IN (?, ?, lower(y) ) )", + stmt => "WHERE ( x IN ( ?,?,lower(y) ) )", # note that outer parens are opened even though literal was requested (RIBASUSHI) bind => [1, 2], test => '-in with a literal arrayrefref', }, { parenthesis_significant => 1, where => { + status => { -in => \"(SELECT status_codes\nFROM states)" }, + }, + # failed to open outer parens on a multi-line query in 1.61 (semifor) + stmt => " WHERE ( status IN ( SELECT status_codes FROM states )) ", + bind => [], + test => '-in multi-line subquery test', + }, + { + parenthesis_significant => 1, + where => { customer => { -in => \[ 'SELECT cust_id FROM cust WHERE balance > ?', 2000,