Skip to main content

Ensure all the specs and tests have been written

Problem

Whenever you are about to start working on a story you’ll want to make sure that all specs and a test plan are complete and available . Let's assume that both, specs and test plans, each have certain issue type.

Solution

You can do this either with a condition or a validator. In either case, add a custom condition (validator) to the transition that starts work on a story and use the following Jira expression:

issue.links
  .filter(li => li.linkedIssue.issueType.name == 'Spec'
             && li.linkedIssue.status.name != 'New').length > 0
&& issue.links
  .filter(li => li.linkedIssue.issueType.name == 'Test Plan'
             && li.linkedIssue.status.name != 'New').length > 0