Test Management System (TMS) using JIRA Customization

39
TMS using JIRA Customization Yagnanarayana Dande

Transcript of Test Management System (TMS) using JIRA Customization

Page 1: Test Management System (TMS) using JIRA Customization

TMS using JIRA CustomizationYagnanarayana Dande

Page 2: Test Management System (TMS) using JIRA Customization

Project/Component/Story-Feature

• In JIRA Project will be top level entity

• Every Project will be having several Components

• Example - Project-1 is a Project and Comp-1,Comp-2 are

components

• Stories will be created per Project and will be associated with

one or more Components

Page 3: Test Management System (TMS) using JIRA Customization

Test Case

New IssueType called Test Case added into JIRA with CFs

Page 4: Test Management System (TMS) using JIRA Customization

Template

Test

Summar

y

Test Steps

Expected Results

Automatio

n Status Test Group

Componen

ts

Requirem

ent

Issue

Type

Affects

Version

Create

….

*Test Steps*

1….

2 ….

3….

*Expected Results*

1…..

2…. Manual Smoke Comp-1 Project1-1

Test

Case v1.3.0

Page 5: Test Management System (TMS) using JIRA Customization

Sample Test Case

Page 6: Test Management System (TMS) using JIRA Customization

Requirement Traceability

Test Case should be linked to Requirement

This allows Requirement Traceability

Page 7: Test Management System (TMS) using JIRA Customization

No. of Test Cases added in Latest Release

Page 8: Test Management System (TMS) using JIRA Customization

Test cycle creation

Page 9: Test Management System (TMS) using JIRA Customization

Assign Test Cases for Execution

Using JQL and Bulk Upload

Page 10: Test Management System (TMS) using JIRA Customization

Test cycle execution assignments

Page 11: Test Management System (TMS) using JIRA Customization

User Dashboard

Page 12: Test Management System (TMS) using JIRA Customization

Test Execution

Page 13: Test Management System (TMS) using JIRA Customization

Test progress in a Test cycle

Page 14: Test Management System (TMS) using JIRA Customization

Test progress at Component level

Page 15: Test Management System (TMS) using JIRA Customization

Test progress at Feature Level

Page 16: Test Management System (TMS) using JIRA Customization

Test execution report with teststeps

Page 17: Test Management System (TMS) using JIRA Customization

Test Cases for Different Platforms(OS)

Page 18: Test Management System (TMS) using JIRA Customization

Test Cases for Different Platforms(OS)

• Create Test Case for a Platform and upon review Clone them if

Test Steps are same for all the Platforms

• Create Different Test Cases for different Platforms if they are

platform dependent Test Cases

• Link a Test Case of different Environments

Page 19: Test Management System (TMS) using JIRA Customization

Creation of Automation Tasks using CSV upload

Page 20: Test Management System (TMS) using JIRA Customization

Test case assignment for automation

• Change Automation Status as “To be Automated” in Test Case

• Create a Sub-Task for Test Case

• Add to appropriate Test Cycle

• Assign it to a QA Engineer

Page 21: Test Management System (TMS) using JIRA Customization

Automation Activity

• QA Engineer looks at User Dashboard for Automation Activities

• QA Engineer will put it in Progress

• Complete it and mark it as Done

• Change Automation Status as “Automated” in Test Case

• Update “Automation Code” with Fully Qualified Class Name and

@Test Method Name

Page 22: Test Management System (TMS) using JIRA Customization

Automation assignments

Page 23: Test Management System (TMS) using JIRA Customization

Automation Progress

Page 24: Test Management System (TMS) using JIRA Customization

Create Regression Tests

• Get All Test Cases from Test Case Repository which are not

invalid

• Export them to CSV

• Change the Test Cycle and Assignee

• Import CSV

• Use Issue Key as Cloners in import menu

Page 25: Test Management System (TMS) using JIRA Customization

No. of Regressions across Versions

• Bug should be linked to Test Case with “is regressed by” link

type, if it a regression Bug.

• If not it should be linked to Test Case with “is caused by”

Page 26: Test Management System (TMS) using JIRA Customization

No. of regressions within Release

Page 27: Test Management System (TMS) using JIRA Customization

Test execution history for a testcase

Page 28: Test Management System (TMS) using JIRA Customization

JIRA Jenkins Integration

Pull Issue DetailsExecute Test Cases

Update Test Results in JIRA

Page 29: Test Management System (TMS) using JIRA Customization

Jenkins Integration

• Get all issues of given Filter

• Get custom field from every Test Case

• Maintain a Map of JIRA ID to Custom Field

• Create a TestNG XML suite Programmatically and run it

• Get results programmatically from TestNG

• Update the issues by using Reverse mapping of Custom Field

to JIRA ID

Page 30: Test Management System (TMS) using JIRA Customization

Jenkins Integration

• https://github.com/rcarz/jira-client

• Create a Filter

• project = Project-1 AND issuetype = "Test Case" AND "Test Cycle" = "Version 4.0 - Cycle 1" AND "Automation Status" =

Automated AND status = "In Progress"

• Build jar from the code in last slide and run on Jenkins.

• This code needs following inputs

– JIRA URL

– JIRA Credentials

– Filter like “filter=10112”

– customField="customfield_10032"

– Note: You can get custom field name from JIRA Rest API and this name is different from what you see in JIRA UI

Page 31: Test Management System (TMS) using JIRA Customization

Add-ons Required

JQL Extensions for Querying linked issues

https://marketplace.atlassian.com/plugins/jql-extensions/cloud/pricing

Page 32: Test Management System (TMS) using JIRA Customization

Import Test Cases from CSV

https://confluence.atlassian.com/adminjiracloud/importing-data-

from-csv-776636762.html#ImportingdatafromCSV-format

Page 33: Test Management System (TMS) using JIRA Customization

Import Test Cases from CSV

Page 34: Test Management System (TMS) using JIRA Customization

Import Test Cases from CSV

Page 35: Test Management System (TMS) using JIRA Customization

Jenkins Integration

package com.company.qa.project.test;

import java.util.ArrayList;

import java.util.Arrays;

import java.util.Collection;

import java.util.HashMap;

import java.util.List;

import java.util.Map;

import org.testng.IReporter;

import org.testng.ISuite;

import org.testng.ISuiteResult;

Page 36: Test Management System (TMS) using JIRA Customization

Issue Links Used

Page 37: Test Management System (TMS) using JIRA Customization

Filters Used

Filter Name JQL

Bugs with Test Cases project = Project1 AND linkType = "is regressed by" AND issuetype = Bug AND affectedVersion = "Version 3.0"

Test Case Repository project = Project1 AND issuetype = "Test Case" AND (linkType not in (clones) OR linkType is EMPTY)

Test Cases Added in Latest Version project = Project1 AND issuetype = "Test Case" AND affectedVersion = "Version 4.0"

Test Cases Caused Regression project = Project1 AND linkType = regresses AND issuetype = "Test Case"

Test Cases With Open Bugs

project = Project1 AND issuetype = "Test Case" AND status = "TC - Failed" AND linkedIssueType = Bug AND

linkedIssueStatus = "To Do"

Test Execution of Latest Test Cycle project = Project1 AND issuetype = "Test Case" AND "Test Cycle" = "Version 4.0 - Cycle 1"

Requirement Traceability project = Project1 AND issuetype = Story AND linkType = "is requirement of"

All Bugs with Test Cases

project = Project1 AND (linkType = "is caused by" OR linkType = "is regressed by") AND issuetype = Bug AND

affectedVersion = "Version 3.0"

Automation Progress project = Project1 AND issuetype = Sub-task AND "Test Cycle" = "Version 4.0 - Cycle 1"

Regression Bugs with Test Cases project = Project1 AND linkType = "is regressed by" AND issuetype = Bug AND affectedVersion = "Version 3.0"

Automated Tests Ready to Run

project = Project1 AND issuetype = "Test Case" AND "Test Cycle" = "Version 4.0 - Cycle 1" AND "Automation

Status" = Automated AND status = "In Progress"

Test Execution History

project = Project1 AND issuetype = "Test Case" AND linkType in (clones) AND linksIssue = Project1-32 ORDER

BY "Test Cycle" DESC

Page 38: Test Management System (TMS) using JIRA Customization

Configuration for Environments

{

"config.version" : "2.0",

"config.project.from.csv" : "false",

"config.encoding" : "UTF-8",

"config.email.suffix" : "@",

"config.field.mappings" : {

"Custom field (Test Group)" : {

"existing.custom.field" : "10026"

},

"Issue Type" : {

"jira.field" : "issuetype"

Page 39: Test Management System (TMS) using JIRA Customization

Thank you

yagna.b

itspila

ni@

gm

ail.c

om