pqd: Removed show-all, shorten, select & print-iterations

This commit is contained in:
Brian Fraser
2013-02-25 13:10:03 -03:00
parent 78cae8b91b
commit 1d9b013bab
14 changed files with 39 additions and 189 deletions

View File

@@ -1526,11 +1526,14 @@ ok(
'New event class has new attrib; default unroll_limit(issue 514)'
);
$ea = new EventAggregator(
groupby => 'arg',
worst => 'Query_time',
unroll_limit => 50,
);
$ea = do {
local $ENV{PT_QUERY_DIGEST_CHECK_ATTRIB_LIMIT} = 50;
new EventAggregator(
groupby => 'arg',
worst => 'Query_time'
);
};
parse_file('t/lib/samples/slowlogs/slow030.txt', $p, $ea);
ok(
!exists $ea->{unrolled_for}->{InnoDB_rec_lock_wait},

View File

@@ -464,7 +464,7 @@ ok(
# #############################################################################
# This test uses the $ea from the Bool pretty printer test above.
my $sorted = $qrf->sort_attribs($ea->get_attributes(), $ea);
my $sorted = $qrf->sort_attribs($ea);
is_deeply(
$sorted,
{
@@ -511,7 +511,7 @@ foreach my $event (@$events) {
}
$ea->calculate_statistical_metrics();
$sorted = $qrf->sort_attribs($ea->get_attributes(), $ea);
$sorted = $qrf->sort_attribs($ea);
is_deeply(
$sorted,
{
@@ -689,7 +689,7 @@ ok(
"t/lib/samples/QueryReportFormatter/report010.txt",
cmd_output => 1,
),
'Truncate one long string'
"Don't truncate one long string"
);
$ea->reset_aggregated_data();
@@ -721,7 +721,7 @@ ok(
"t/lib/samples/QueryReportFormatter/report011.txt",
cmd_output => 1,
),
'Truncate multiple long strings'
"Don't truncate multiple long strings"
);
$ea->reset_aggregated_data();
@@ -753,7 +753,7 @@ ok(
"t/lib/samples/QueryReportFormatter/report012.txt",
cmd_output => 1,
),
'Truncate multiple strings longer than whole line'
"Don't truncate multiple strings longer than whole line"
);
# #############################################################################
@@ -881,16 +881,6 @@ ok(
"IPs not shortened with more"
);
# Test show_all.
@ARGV = qw(--show-all host);
$o->get_opts();
$qrf = new QueryReportFormatter(
OptionParser => $o,
QueryRewriter => $qr,
QueryParser => $qp,
Quoter => $q,
ExplainAnalyzer => $ex,
);
$result = $qrf->event_report(
ea => $ea,
select => [ qw(Query_time host) ],

View File

@@ -7,4 +7,4 @@
# Count 100 3
# Exec time 100 6s 1s 3s 2s 3s 780ms 2s
# String:
# foo Hi. I'm a... (1/33%), Me too! I'... (1/33%)... 1 more
# foo Hi. I'm a... (1/33%), Me too! I'... (1/33%), Number 3 l... (1/33%)

View File

@@ -5,4 +5,4 @@
# Count 100 2
# Exec time 100 16s 8s 8s 8s 8s 0 8s
# String:
# Hosts 123.123.123.456 (1/50%)... 1 more
# Hosts 123.123.123.456 (1/50%), 123.123.123.789 (1/50%)

View File

@@ -5,4 +5,4 @@
# Count 100 3
# Exec time 100 24s 8s 8s 8s 8s 0 8s
# String:
# Hosts 123.123.123.456 (1/33%)... 2 more
# Hosts 123.123.123.456 (1/33%), 123.123.123.789 (1/33%), 123.123.123.999 (1/33%)