Package randoop.test
Class PostConditionCheckGenerator
java.lang.Object
randoop.test.TestCheckGenerator
randoop.test.PostConditionCheckGenerator
Checks the given post-conditions after the last statement of a sequence.
-
Field Summary
Modifier and TypeFieldDescriptionprivate final List<ExecutableBooleanExpression>
the post-conditions -
Constructor Summary
ConstructorDescriptionPostConditionCheckGenerator
(List<ExecutableBooleanExpression> postConditions) Create aTestCheckGenerator
to test the given post-condition. -
Method Summary
Modifier and TypeMethodDescriptionprivate Object[]
addNullReceiver
(Object[] values) TestChecks<?>
Tests all of the post-conditions against the values in the givenExecutableSequence
, and if the condition is not satisfied returns aErrorRevealingChecks
.Methods inherited from class randoop.test.TestCheckGenerator
hasGenerator
-
Field Details
-
postConditions
the post-conditions
-
-
Constructor Details
-
PostConditionCheckGenerator
Create aTestCheckGenerator
to test the given post-condition.- Parameters:
postConditions
- the post-condition to be tested in generatedTestChecks
-
-
Method Details
-
generateTestChecks
Tests all of the post-conditions against the values in the givenExecutableSequence
, and if the condition is not satisfied returns aErrorRevealingChecks
.Note that the operation input values passed to the post-condition are the values post-execution.
- Specified by:
generateTestChecks
in classTestCheckGenerator
- Parameters:
eseq
- the sequence for which checks are generated- Returns:
- the
ErrorRevealingChecks
with aPostConditionCheck
if the post-condition fails on the sequence, annull
otherwise
-
addNullReceiver
-