Jira Integration with Selenium || Raise a bug for failure test cases || No Manual Bug in JIRA


Filing issues in JIRA is boring, wanna do with Simply Cool Automation on Selenium... 


I have tried by importing in Product and ran automation from the script, issues are getting filed in JIRA for the failed test cases.

Here we go with Selenium script to raise a bug for Failure Test Cases to direct punch on JIRA.


Step 1 : 

Maven Dependencies to add in our POM.xml

<!-- https://mvnrepository.com/artifact/net.rcarz/jira-client -->
<dependency>
<groupId>net.rcarz</groupId>
<artifactId>jira-client</artifactId>
<version>0.5</version>
</dependency>

Step 2 :

Add two packages in your project, say... com.listeners and com.jira

*Under package com.listeners
     =TestJiraListener.java
*Under package com.jira
     =JiraPolicy.java
     =JiraServiceProvider.java

Add these two files in the respective Packages, refer attachment.

Step 3 : 

Under listener package in TestJiraListener.java file, we need to provide JIRA Authentication API token with our Email ID.

Here is the piece of code change in the TestJiraListner.java file