mirror of
https://github.com/lm-sensors/lm-sensors.git
synced 2026-11-17 19:30:26 +00:00
Run regression tests under valgrind, if it is available.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4275 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
1 parent
c510d7934f
commit
7bb9db17d8
1 file changed
+8
-1
@@ -47,7 +47,14 @@ my @scenarios = (
|
||||
|
||||
plan tests => ($#scenarios + 1) * 3;
|
||||
|
||||
$test = Test::Cmd->new(prog => 'test-scanner', workdir => '');
|
||||
chomp(my $valgrind = `which valgrind 2>/dev/null`);
|
||||
|
||||
if ($valgrind) {
|
||||
$test = Test::Cmd->new(prog => "$valgrind --tool=memcheck --show-reachable=yes --leak-check=full --quiet ./test-scanner", workdir => '');
|
||||
} else {
|
||||
diag("Couldn't find valgrind(1), running tests without it...");
|
||||
$test = Test::Cmd->new(prog => "test-scanner", workdir => '');
|
||||
}
|
||||
|
||||
foreach $scenario (@scenarios) {
|
||||
my ($filename, @stdin, @stdout, @expout, @stderr, @experr, @diff);
|
||||
|
||||
Reference in new issue
Block a user