// resolve as false-positive
.transition(Transition.builder(DefaultTransitions.FALSE_POSITIVE)
.from(Issue.STATUS_OPEN).to(Issue.STATUS_RESOLVED)
- .conditions(new IsManual(false))
.functions(new SetResolution(Issue.RESOLUTION_FALSE_POSITIVE), SetAssignee.UNASSIGN)
.build())
.transition(Transition.builder(DefaultTransitions.FALSE_POSITIVE)
.from(Issue.STATUS_REOPENED).to(Issue.STATUS_RESOLVED)
- .conditions(new IsManual(false))
.functions(new SetResolution(Issue.RESOLUTION_FALSE_POSITIVE), SetAssignee.UNASSIGN)
.build())
.transition(Transition.builder(DefaultTransitions.FALSE_POSITIVE)
.from(Issue.STATUS_CONFIRMED).to(Issue.STATUS_RESOLVED)
- .conditions(new IsManual(false))
.functions(new SetResolution(Issue.RESOLUTION_FALSE_POSITIVE), SetAssignee.UNASSIGN)
.build())
.build())
.transition(Transition.builder("automaticclosemanual")
.from(Issue.STATUS_RESOLVED).to(Issue.STATUS_CLOSED)
- .conditions(new IsEndOfLife(false), new HasResolution(Issue.RESOLUTION_FIXED), new IsManual(true))
+ .conditions(new IsEndOfLife(false), new IsManual(true))
.functions(new SetCloseDate(true))
.automatic()
.build())
assertThat(workflow.outTransitions(issue)).containsOnly(
Transition.create("confirm", "OPEN", "CONFIRMED"),
- Transition.create("resolve", "OPEN", "RESOLVED")
+ Transition.create("resolve", "OPEN", "RESOLVED"),
+ Transition.create("falsepositive", "OPEN", "RESOLVED")
);
workflow.doTransition(issue, "resolve", mock(IssueChangeContext.class));
assertThat(workflow.outTransitions(issue)).containsOnly(
Transition.create("confirm", "OPEN", "CONFIRMED"),
- Transition.create("resolve", "OPEN", "RESOLVED")
+ Transition.create("resolve", "OPEN", "RESOLVED"),
+ Transition.create("falsepositive", "OPEN", "RESOLVED")
);
workflow.doTransition(issue, "confirm", mock(IssueChangeContext.class));
assertThat(workflow.outTransitions(issue)).containsOnly(
Transition.create("unconfirm", "CONFIRMED", "REOPENED"),
- Transition.create("resolve", "CONFIRMED", "RESOLVED")
+ Transition.create("resolve", "CONFIRMED", "RESOLVED"),
+ Transition.create("falsepositive", "CONFIRMED", "RESOLVED")
);
// keep confirmed and unresolved