Next: PlUnit Tests Expected to Fail, Previous: PlUnit Determinate Tests, Up: PlUnit A Unit Test Box [Contents][Index]
Nondeterminate tests succeed zero or more times. Their results can be
tested using findall/3
followed by a value-check. The following
are equivalent tests:
test(member5) :- findall(X, member(X, [a,b,c]), Xs), Xs == [a,b,c]. test(member6, true(Xs == [a,b,c])) :- findall(X, member(X, [a,b,c]), Xs).