Skip to content

Commit 4cd498e

Browse files
committed
Expanded docs of verify_results test helper function.
1 parent 66e7413 commit 4cd498e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

docs/contribute/testing.adoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -215,10 +215,18 @@ a `RESULTS_FILE`:
215215
[source,bash]
216216
----
217217
verify_results TYPE CONTENT_FILE RESULTS_FILE COUNT
218+
219+
verify_results "def" test_probe_foo.xml results.xml 13
218220
----
219221

222+
The function extracts the actual test/definition result, and compares it with the respective test/definition comment.
223+
So for example, if the test contains `comment="true"`, the test passes only if result of the respective test is `true`,
224+
if `comment="false"`, a `false` result is expected.
225+
If the comment is missing or it has other value, it is assumed that the result shouldn't be neither `true` or `false`.
226+
220227
NOTE: This function expects that the OVAL `TYPE` is numbered from `1` to `COUNT`
221228
in the `RESULTS_FILE`.
229+
Type is typically `def` or `tst` for definitions and tests respectively.
222230

223231

224232
==== assert_exists function

0 commit comments

Comments
 (0)