mirror of
https://github.com/percona/percona-toolkit.git
synced 2025-09-27 16:12:04 +00:00
Fix pt-table-checksum/basics.t test that was affected by bug 1087804, and test for bug 1087804.
This commit is contained in:
@@ -355,17 +355,40 @@ $output = output(
|
|||||||
stderr => 1,
|
stderr => 1,
|
||||||
);
|
);
|
||||||
|
|
||||||
is(
|
# This test no longer works because of
|
||||||
$exit_status,
|
# https://bugs.launchpad.net/percona-toolkit/+bug/1087804
|
||||||
0,
|
# So comment out this test...
|
||||||
"No host in DSN, zero exit status"
|
#is(
|
||||||
);
|
# $exit_status,
|
||||||
|
# 0,
|
||||||
|
# "No host in DSN, zero exit status"
|
||||||
|
#) or diag($output);
|
||||||
|
|
||||||
|
# ... and use this one instead:
|
||||||
|
like(
|
||||||
|
$output,
|
||||||
|
qr/sakila.store/,
|
||||||
|
"No host in DSN, checksums happened"
|
||||||
|
) or diag($output);
|
||||||
|
|
||||||
is(
|
is(
|
||||||
PerconaTest::count_checksum_results($output, 'errors'),
|
PerconaTest::count_checksum_results($output, 'errors'),
|
||||||
0,
|
0,
|
||||||
"No host in DSN, 0 errors"
|
"No host in DSN, 0 errors"
|
||||||
);
|
) or diag($output);
|
||||||
|
|
||||||
|
# While we're at it, we might as well test bug 1087804:
|
||||||
|
like(
|
||||||
|
$output,
|
||||||
|
qr/no slaves were found/,
|
||||||
|
"Warns when no slave are found (bug 1087804)"
|
||||||
|
) or diag($output);
|
||||||
|
|
||||||
|
is(
|
||||||
|
$exit_status,
|
||||||
|
1,
|
||||||
|
"Exit status 1 when no slaves are found (bug 1087804)"
|
||||||
|
) or diag($output);
|
||||||
|
|
||||||
# #############################################################################
|
# #############################################################################
|
||||||
# Test --where.
|
# Test --where.
|
||||||
|
Reference in New Issue
Block a user