X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F76select.t;h=8f45fd056d2984a0c04e0137750fb2e27cf30367;hb=d52d4d6e066eca4c85c5f4f6cf7b005f0dc883bc;hp=d7c2b4a5788c26db882a198548039f7acb75fac6;hpb=c4af4c4ec79434f87a069a313db7846b2bf40530;p=dbsrgits%2FDBIx-Class.git diff --git a/t/76select.t b/t/76select.t index d7c2b4a..8f45fd0 100644 --- a/t/76select.t +++ b/t/76select.t @@ -89,13 +89,13 @@ lives_ok(sub { }, 'columns 2nd rscolumn present'); lives_ok(sub { - $rs->first->artist->get_column('name') -}, 'columns 3rd rscolumn present'); + $rs->first->artist->get_column('name') +}, 'columns 3rd rscolumn present'); $rs = $schema->resultset('CD')->search({}, - { + { 'join' => 'artist', '+columns' => ['cdid', 'title', 'artist.name'], } @@ -109,7 +109,7 @@ is_same_sql_bind ( ); lives_ok(sub { - $rs->first->get_column('cdid') + $rs->first->get_column('cdid') }, 'columns 1st rscolumn present'); lives_ok(sub { @@ -153,36 +153,16 @@ my $sub_rs = $rs->search ({}, } ); -is_deeply ( +is_deeply( $sub_rs->single, { - artist => 1, - track_position => 2, - tracks => - { - trackid => 17, - title => 'Apiary', - }, + artist => 1, + tracks => { + title => 'Apiary', + trackid => 17, + }, }, 'columns/select/as fold properly on sub-searches', ); -TODO: { - local $TODO = "Multi-collapsing still doesn't work right - HRI should be getting an arrayref, not an individual hash"; - is_deeply ( - $sub_rs->single, - { - artist => 1, - track_position => 2, - tracks => [ - { - trackid => 17, - title => 'Apiary', - }, - ], - }, - 'columns/select/as fold properly on sub-searches', - ); -} - done_testing;