forked from lix-project/hydra
fix(t/evaluator/evaluate-oom): check that the exit value of the systemd-run
check is zero. Rework skip messages
This commit is contained in:
parent
e917d9e546
commit
013a1dcabc
|
@ -4,8 +4,9 @@ use Setup;
|
||||||
use Test2::V0;
|
use Test2::V0;
|
||||||
use Hydra::Helper::Exec;
|
use Hydra::Helper::Exec;
|
||||||
|
|
||||||
|
my $sd_res;
|
||||||
eval {
|
eval {
|
||||||
captureStdoutStderr(3, (
|
($sd_res) = captureStdoutStderr(3, (
|
||||||
"systemd-run",
|
"systemd-run",
|
||||||
"--user",
|
"--user",
|
||||||
"--collect",
|
"--collect",
|
||||||
|
@ -16,8 +17,9 @@ eval {
|
||||||
"true"
|
"true"
|
||||||
));
|
));
|
||||||
} or do {
|
} or do {
|
||||||
skip_all("systemd-run does not work in this environment");
|
skip_all("`systemd-run` failed when invoked in this environment");
|
||||||
};
|
};
|
||||||
|
if ($sd_res != 0) { skip_all("`systemd-run` returned non-zero when executing `true` (expected 0)"); }
|
||||||
|
|
||||||
my ($res, $stdout, $stderr) = captureStdoutStderr(60, (
|
my ($res, $stdout, $stderr) = captureStdoutStderr(60, (
|
||||||
"systemd-run",
|
"systemd-run",
|
||||||
|
|
Loading…
Reference in a new issue