X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F19quotes_newstyle.t;h=3e7595aab975a94a1d4016418843e281d9200473;hb=bda35a4c8068f8e2e263ee09c581905297dd6974;hp=748b11295c2a68e88c317472891f371479952b61;hpb=c61a0748004eaaeb8207dc8a933ed5213ccce3e6;p=dbsrgits%2FDBIx-Class.git diff --git a/t/19quotes_newstyle.t b/t/19quotes_newstyle.t index 748b112..3e7595a 100644 --- a/t/19quotes_newstyle.t +++ b/t/19quotes_newstyle.t @@ -19,7 +19,7 @@ use_ok('DBIC::DebugObj'); my $schema = DBICTest->init_schema(); -diag('Testing against ' . join(' ', map { $schema->storage->dbh->get_info($_) } qw/17 18/)); +#diag('Testing against ' . join(' ', map { $schema->storage->dbh->get_info($_) } qw/17 18/)); my $dsn = $schema->storage->_dbi_connect_info->[0]; $schema->connection( @@ -30,7 +30,7 @@ $schema->connection( { quote_char => '`', name_sep => '.' }, ); -my ($sql, @bind) = (''); +my ($sql, @bind); $schema->storage->debugobj(DBIC::DebugObj->new(\$sql, \@bind)), $schema->storage->debug(1); @@ -42,7 +42,7 @@ $rs = $schema->resultset('CD')->search( eval { $rs->count }; is_same_sql_bind( $sql, \@bind, - "SELECT COUNT( * ) FROM `cd` `me` JOIN `artist` `artist` ON ( `artist`.`artistid` = `me`.`artist` ) WHERE ( `artist`.`name` = ? AND `me`.`year` = ? )", ["'Caterwauler McCrae'", "'2001'"], + "SELECT COUNT( * ) FROM cd `me` JOIN `artist` `artist` ON ( `artist`.`artistid` = `me`.`artist` ) WHERE ( `artist`.`name` = ? AND `me`.`year` = ? )", ["'Caterwauler McCrae'", "'2001'"], 'got correct SQL for count query with quoting' ); @@ -73,7 +73,7 @@ $rs = $schema->resultset('CD')->search( eval { $rs->count }; is_same_sql_bind( $sql, \@bind, - "SELECT COUNT( * ) FROM [cd] [me] JOIN [artist] [artist] ON ( [artist].[artistid] = [me].[artist] ) WHERE ( [artist].[name] = ? AND [me].[year] = ? )", ["'Caterwauler McCrae'", "'2001'"], + "SELECT COUNT( * ) FROM cd [me] JOIN [artist] [artist] ON ( [artist].[artistid] = [me].[artist] ) WHERE ( [artist].[name] = ? AND [me].[year] = ? )", ["'Caterwauler McCrae'", "'2001'"], 'got correct SQL for count query with bracket quoting' );