summaryrefslogtreecommitdiff
path: root/mysql-test/suite/unit/suite.pm
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/suite/unit/suite.pm')
-rw-r--r--mysql-test/suite/unit/suite.pm13
1 files changed, 11 insertions, 2 deletions
diff --git a/mysql-test/suite/unit/suite.pm b/mysql-test/suite/unit/suite.pm
index 78d82ccb31d..966fd278a52 100644
--- a/mysql-test/suite/unit/suite.pm
+++ b/mysql-test/suite/unit/suite.pm
@@ -10,14 +10,23 @@ sub list_cases {
sub start_test {
my ($self, $tinfo)= @_;
- my $args=[ ];
+ my $args;
+ my $path;
+ my $cmd = $self->{ctests}->{$tinfo->{shortname}};
+
+ if ($cmd =~ /[ "'><%!*?]/) {
+ ($path, $args) = ('/bin/sh', [ '-c', $cmd ])
+ } else {
+ ($path, $args) = ($cmd, , [ ])
+ }
+
my $oldpwd=getcwd();
chdir $::opt_vardir;
my $proc=My::SafeProcess->new
(
name => $tinfo->{shortname},
- path => $self->{ctests}->{$tinfo->{shortname}},
+ path => $path,
args => \$args,
append => 1,
output => $::path_current_testlog,