public void failedRejectionRule() {
// A single rejection should reject the whole translation no matter what
// the other rules say
assertThat(CopyTransWork.determineContentStateFromRuleList(Lists
.newArrayList(
new MatchRulePair(Suppliers.ofInstance(false),
DOWNGRADE_TO_FUZZY),
new MatchRulePair(Suppliers.ofInstance(false),
REJECT)
),
true, Translated
), is(New));
assertThat(CopyTransWork.determineContentStateFromRuleList(Lists
.newArrayList(new MatchRulePair(Suppliers.ofInstance(true),
IGNORE), new MatchRulePair(Suppliers.ofInstance(false),
REJECT)), false, Translated), is(New));
assertThat(CopyTransWork.determineContentStateFromRuleList(Lists
.newArrayList(new MatchRulePair(Suppliers.ofInstance(false),
REJECT), new MatchRulePair(Suppliers.ofInstance(false),
DOWNGRADE_TO_FUZZY)), true, Translated), is(New));
assertThat(CopyTransWork.determineContentStateFromRuleList(Lists
.newArrayList(new MatchRulePair(Suppliers.ofInstance(false),
REJECT), new MatchRulePair(Suppliers.ofInstance(true),
IGNORE)), false, Translated), is(New));
}