From 98190d25e74a67a6bdd37271dfd2aa9652e7ad9f Mon Sep 17 00:00:00 2001 From: Brian Fraser Date: Wed, 21 Nov 2012 13:23:05 -0300 Subject: [PATCH] t/pt-archiver/issue_1225.t: Don't assume that the first two values in an autoinc table will have indexes 1 & 2 --- t/pt-archiver/issue_1225.t | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/t/pt-archiver/issue_1225.t b/t/pt-archiver/issue_1225.t index f99489ec..857e3b1b 100644 --- a/t/pt-archiver/issue_1225.t +++ b/t/pt-archiver/issue_1225.t @@ -34,11 +34,11 @@ my $output; $sb->load_file('master', 't/pt-archiver/samples/issue_1225.sql'); $dbh->do('set names "utf8"'); -my $original_rows = $dbh->selectall_arrayref('select * from issue_1225.t where i in (1, 2)'); +my $original_rows = $dbh->selectall_arrayref('select c from issue_1225.t limit 2'); is_deeply( $original_rows, - [ [ 1, 'が'], # Your terminal must be UTF8 to see this Japanese character. - [ 2, 'が'], + [ ['が'], # Your terminal must be UTF8 to see this Japanese character. + ['が'], ], "Inserted UTF8 data" ); @@ -61,10 +61,10 @@ $output = output( }, ); -my $archived_rows = $dbh->selectall_arrayref('select * from issue_1225.a where i in (1, 2)'); +my $archived_rows = $dbh->selectall_arrayref('select c from issue_1225.a limit 2'); ok( - $original_rows->[0]->[1] ne $archived_rows->[0]->[1], + $original_rows->[0]->[0] ne $archived_rows->[0]->[0], "UTF8 characters lost when cxn isn't also UTF8" ); @@ -78,7 +78,7 @@ $output = output( }, ); -$archived_rows = $dbh->selectall_arrayref('select * from issue_1225.a where i in (1, 2)'); +$archived_rows = $dbh->selectall_arrayref('select c from issue_1225.a limit 2'); is_deeply( $original_rows,