1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-21 18:41:03 +00:00

tests: add "shellcheck" tests for "ksh" scripts

This commit is contained in:
Lars Kruse 2018-03-09 05:33:37 +01:00
parent f08727035f
commit 6c0e154e07
2 changed files with 15 additions and 7 deletions

View file

@ -85,12 +85,20 @@ sub process_file {
};
}
elsif ( $interpreter =~ m{/bin/ksh} ) {
run_check(
{ command => [ 'ksh', '-n', $file ],
description => 'ksh syntax check',
filename => $filename
}
);
subtest $filename => sub {
plan tests => 2;
run_check(
{ command => [ 'ksh', '-n', $file ],
description => 'ksh syntax check',
filename => $filename
}
);
run_check(
{ command => [ 'shellcheck', $file ],
description => 'shellcheck'
}
);
}
}
elsif ( $interpreter =~ m{bash} ) {
run_check(