mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-07-21 18:41:03 +00:00
tests: test compiling with python3 if given as shebang interpreter
Currently plugins fail to compile if they use Python 3 syntax features, even though they use a correct shebang.
This commit is contained in:
parent
67b0241e90
commit
d1a8965b5a
1 changed files with 8 additions and 0 deletions
8
t/test.t
8
t/test.t
|
@ -94,6 +94,14 @@ sub process_file {
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
elsif ( $interpreter =~ m{python3} ) {
|
||||||
|
run_check(
|
||||||
|
{ command => [ 'python3', '-m', 'py_compile', $file ],
|
||||||
|
description => 'python3 compile',
|
||||||
|
filename => $filename
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
||||||
elsif ( $interpreter =~ m{python} ) {
|
elsif ( $interpreter =~ m{python} ) {
|
||||||
run_check(
|
run_check(
|
||||||
{ command => [ 'python', '-m', 'py_compile', $file ],
|
{ command => [ 'python', '-m', 'py_compile', $file ],
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue