~percona-toolkit-dev/percona-toolkit/pqd-enhanced-resume-file

« back to all changes in this revision

Viewing changes to t/pt-query-digest/option_sanity.t

  • Committer: Brian Fraser
  • Date: 2013-03-01 19:35:43 UTC
  • mto: (530.5.1 clean-up-pqd-2.2)
  • mto: This revision was merged to the branch mainline in revision 549.
  • Revision ID: fraserbn@gmail.com-20130301193543-y0llx4rlv4pd14vs
Split --review and --history

Show diffs side-by-side

added added

removed removed

Lines of Context:
19
19
my $output;
20
20
 
21
21
# #############################################################################
22
 
# Test cmd line op sanity.
23
 
# #############################################################################
24
 
for my $opt (qw(review-table history-table)) {
25
 
   $output = `$cmd --review h=127.1,P=12345,u=msandbox,p=msandbox --$opt test`;
26
 
   like($output, qr/--$opt should be passed a/, "Dies if no database part in --$opt");
27
 
}
28
 
 
29
 
$output = `$cmd --review h=127.1,P=12345,u=msandbox,p=msandbox,D=test,t=test`;
30
 
like($output, qr/--review does not accept a t option/, 'Dies if t part in --review DSN');
31
 
 
32
 
like(
33
 
   $help,
34
 
   qr/review-table\s+\Qpercona_schema.query_review\E/,
35
 
   "--review-table has a sane default"
36
 
);
37
 
 
38
 
like(
39
 
   $help,
40
 
   qr/history-table\s+\Qpercona_schema.query_history\E/,
41
 
   "--history-table has a sane default"
42
 
);
43
 
 
44
 
# #############################################################################
45
22
# https://bugs.launchpad.net/percona-toolkit/+bug/885382
46
23
# pt-query-digest --embedded-attributes doesn't check cardinality
47
24
# #############################################################################