pt-qry-dgst: clearer doc about type binlog. Also try to detect binlog file type-1377888

This commit is contained in:
Frank Cizmich
2014-10-06 17:25:52 -02:00
parent 4ba15b4887
commit 1887ae5770
2 changed files with 42 additions and 3 deletions

View File

@@ -9,7 +9,7 @@ BEGIN {
use strict;
use warnings FATAL => 'all';
use English qw(-no_match_vars);
use Test::More tests => 3;
use Test::More tests => 4;
use PerconaTest;
require "$trunk/bin/pt-query-digest";
@@ -46,6 +46,19 @@ ok(
'Analysis for binlog011 - Handles 5.6 binlog with checksum CRC32',
) or diag($test_diff);
# #############################################################################
# Issue 1377888: refuse to parse raw binary log
# #############################################################################
my $output = `$trunk/bin/pt-query-digest --type binlog '$trunk/t/pt-query-digest/samples/raw_binlog.log' 2>&1`;
ok(
$output =~ /mysqlbinlog/i ,
'Refuses to parse raw binlog file.'
);
# #############################################################################
# Done.
# #############################################################################