File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
tests/probes/environmentvariable58 Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -24,13 +24,16 @@ function test_probes_environmentvariable58 {
24
24
local ret_val=0;
25
25
local DF=" $1 .xml"
26
26
local RF=" $1 .results.xml"
27
+ echo " result file: $RF "
28
+ local stderr=$( mktemp $1 .err.XXXXXX)
29
+ echo " stderr file: $stderr "
27
30
28
31
[ -f $RF ] && rm -f $RF
29
32
30
33
bash ${srcdir} /$1 .xml.sh > $DF
31
34
LINES=$?
32
35
33
- $OSCAP oval eval --results $RF $DF
36
+ $OSCAP oval eval --results $RF $DF 2> $stderr
34
37
35
38
if [ -f $RF ]; then
36
39
verify_results " def" $DF $RF 1 && verify_results " tst" $DF $RF $LINES
@@ -39,6 +42,11 @@ function test_probes_environmentvariable58 {
39
42
ret_val=1
40
43
fi
41
44
45
+ # Test fails if there are any warnings or "Entity has no value" on stderr.
46
+ echo " Verify that there are no warnings on stderr"
47
+ grep -Ei " (W:|Entity has no value)" $stderr && ret_val=1
48
+
49
+ rm $stderr
42
50
return $ret_val
43
51
}
44
52
You can’t perform that action at this time.
0 commit comments