mirror of
https://github.com/percona/percona-toolkit.git
synced 2025-09-02 02:34:19 +00:00
Start testing --save-results. Let $cmd be a file in PerconaTest.pm. Remove 'at ... line N' from EventExecutor.pm errors.
This commit is contained in:
@@ -561,8 +561,13 @@ sub no_diff {
|
||||
die "I need a cmd argument" unless $cmd;
|
||||
die "I need an expected_output argument" unless $expected_output;
|
||||
|
||||
die "$expected_output does not exist" unless -f "$trunk/$expected_output";
|
||||
$expected_output = "$trunk/$expected_output";
|
||||
if ( $args{full_path} ) {
|
||||
die "$expected_output does not exist" unless -f $expected_output;
|
||||
}
|
||||
else {
|
||||
die "$expected_output does not exist" unless -f "$trunk/$expected_output";
|
||||
$expected_output = "$trunk/$expected_output";
|
||||
}
|
||||
|
||||
my $tmp_file = '/tmp/percona-toolkit-test-output.txt';
|
||||
my $tmp_file_orig = '/tmp/percona-toolkit-test-output-original.txt';
|
||||
@@ -582,6 +587,9 @@ sub no_diff {
|
||||
print $tmp_fh $cmd;
|
||||
close $tmp_fh;
|
||||
}
|
||||
elsif ( -f $cmd ) {
|
||||
`cp $cmd $tmp_file`;
|
||||
}
|
||||
else {
|
||||
`$cmd > $tmp_file`;
|
||||
}
|
||||
|
Reference in New Issue
Block a user