Merge lp:~percona-toolkit-dev/percona-toolkit/fix-osc-repl-bug-933232.

This commit is contained in:
Daniel Nichter
2012-03-02 13:29:44 -08:00
4 changed files with 62 additions and 12 deletions
+14 -1
View File
@@ -30,13 +30,26 @@ else {
my $output = "";
my $cnf = '/tmp/12345/my.sandbox.cnf';
my @args = ('-F', $cnf);
my @args = ('-F', $cnf, '--execute');
my $exit = 0;
my $rows;
$sb->load_file('master', "t/pt-online-schema-change/samples/small_table.sql");
$dbh->do('use mkosc');
# #############################################################################
# Tool shouldn't run without --execute (bug 933232).
# #############################################################################
$output = output(
sub { pt_online_schema_change::main('h=127.1,P=12345,u=msandbox,p=msandbox,D=mkosc,t=a') },
);
like(
$output,
qr/you did not specify --execute/,
"Doesn't run without --execute"
);
# #############################################################################
# --check-tables-and-exit
# #############################################################################