public interface SingleConstraintAssertion
| Modifier and Type | Method and Description |
|---|---|
default void |
penalizesBy(BigDecimal matchWeightTotal)
As defined by
penalizesBy(int). |
void |
penalizesBy(BigDecimal matchWeightTotal,
String message)
As defined by
penalizesBy(int). |
default void |
penalizesBy(int matchWeightTotal)
Asserts that the
Constraint being tested, given a set of facts, results in a specific penalty. |
void |
penalizesBy(int matchWeightTotal,
String message)
As defined by
penalizesBy(int). |
default void |
penalizesBy(long matchWeightTotal)
As defined by
penalizesBy(int). |
void |
penalizesBy(long matchWeightTotal,
String message)
As defined by
penalizesBy(int). |
default void |
rewardsWith(BigDecimal matchWeightTotal)
As defined by
rewardsWith(int). |
void |
rewardsWith(BigDecimal matchWeightTotal,
String message)
As defined by
rewardsWith(int). |
default void |
rewardsWith(int matchWeightTotal)
Asserts that the
Constraint being tested, given a set of facts, results in a specific reward. |
void |
rewardsWith(int matchWeightTotal,
String message)
As defined by
rewardsWith(int). |
default void |
rewardsWith(long matchWeightTotal)
As defined by
rewardsWith(int). |
void |
rewardsWith(long matchWeightTotal,
String message)
As defined by
rewardsWith(int). |
default void penalizesBy(int matchWeightTotal)
Constraint being tested, given a set of facts, results in a specific penalty.
Ignores the constraint weight: it only asserts the match weights.
For example: a match with a match weight of 10 on a constraint with a constraint weight of -2hard
reduces the score by -20hard. In that case, this assertion checks for 10.
An int matchWeightTotal automatically casts to long for long scores.
matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.AssertionError - when the expected penalty is not observedvoid penalizesBy(int matchWeightTotal,
String message)
penalizesBy(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.message - sometimes null, description of the scenario being assertedAssertionError - when the expected penalty is not observeddefault void penalizesBy(long matchWeightTotal)
penalizesBy(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.AssertionError - when the expected penalty is not observedvoid penalizesBy(long matchWeightTotal,
String message)
penalizesBy(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.message - sometimes null, description of the scenario being assertedAssertionError - when the expected penalty is not observeddefault void penalizesBy(BigDecimal matchWeightTotal)
penalizesBy(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.AssertionError - when the expected penalty is not observedvoid penalizesBy(BigDecimal matchWeightTotal, String message)
penalizesBy(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.message - sometimes null, description of the scenario being assertedAssertionError - when the expected penalty is not observeddefault void rewardsWith(int matchWeightTotal)
Constraint being tested, given a set of facts, results in a specific reward.
Ignores the constraint weight: it only asserts the match weights.
For example: a match with a match weight of 10 on a constraint with a constraint weight of -2hard
reduces the score by -20hard. In that case, this assertion checks for 10.
An int matchWeightTotal automatically casts to long for long scores.
matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.AssertionError - when the expected reward is not observedvoid rewardsWith(int matchWeightTotal,
String message)
rewardsWith(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.message - sometimes null, description of the scenario being assertedAssertionError - when the expected reward is not observeddefault void rewardsWith(long matchWeightTotal)
rewardsWith(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.AssertionError - when the expected reward is not observedvoid rewardsWith(long matchWeightTotal,
String message)
rewardsWith(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.message - sometimes null, description of the scenario being assertedAssertionError - when the expected reward is not observeddefault void rewardsWith(BigDecimal matchWeightTotal)
rewardsWith(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.AssertionError - when the expected reward is not observedvoid rewardsWith(BigDecimal matchWeightTotal, String message)
rewardsWith(int).matchWeightTotal - at least 0, expected sum of match weights of matches of the constraint.message - sometimes null, description of the scenario being assertedAssertionError - when the expected reward is not observedCopyright © 2006–2021 JBoss by Red Hat. All rights reserved.