Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In case of Cloud instance for QMetry for JIRA, select the Cloud option and fill in the required data.


Image RemovedImage Added

You can get more information regarding fields by clicking on the Help icon for respective fields. It explains what to enter in that particular field.

...


Parameter

Type

Required

Description

API Key

string

Yes

Your API Key. API Key is unique for a specific user in a single project. The result will be imported for the project associated with the given API Key.

Format

selection

Yes

Format of result file to be imported. Supported formats:

cucumber/json testng/xml junit/xml QAF hpuft/xml specflow/json

File

string

Yes

Path to your result file to be uploaded.

Example : The Jenkins plugin is expecting the file in Jenkins Workspace. 
If your workspace name is WithoutSouceCode, then you will find a folder name with "WithoutSouceCode" in your installation directory like Jenkins/Home/workspace/WithoutSouceCode. 
Your result file should be under Jenkins/Home/workspace/WithoutSouceCode/Testng-result.xml. 
The path that should be set in plugin configuration is "/Testng-result.xml"

If your automation generates multiple result files of the supported format in a folder then provide the absolute path till the folder name(It should not be the path till workspace). QMetry plugin will zip all supported format files and upload them to QMetry. 

Test Cycle To Reuse

stringNoKey of the test cycle to be reused.

Upload Screenshots

checkboxNoCheck to upload attachments in execution. Default value: false.

Environment

stringNoName of the environment on which test cycle has to be executed.
Build

string

NoName of the build for test cycle execution.


Test Case and Test Cycle Fields

Parameter

Type

Required

Description

Summary (

For

only for Test Cycle)

string

No

Summary of test cycle.

Description

string

No

Description of test case/test cycle

Priority

string

No

Priority to be added to the test case/test cycle.

Status

string

No

Status to be added to the test case/test cycle.

Components

string

No

Comma separated names of Components to be added to the test case/test cycle.

Labels

string

No

Comma separated names of Labels to be added to the test case/test cycle.

Fix Version Id (How to find the Fix Version Id)

number

No

Id of Fix Version to be added to the test case/test cycle.

Sprint Id (How to find the Sprint Id)

number

No

Id of Sprint to be added to the test case/test cycle.

Custom Fields

Assignee

string

No

Comma separated custom fields in JSON array.

Server

In case of Server instance for QMetry for Jira, select the Server option and fill in the required data.

Image Removed

Parameters for Server instance:

Parameter

Type

Required

Description

Jira URLstringYesEnter Jira URL.

Username

string

Yes

Jira Username.

Password

string

Yes

Password for Jira instance.

Automation API Key

string

Yes

Your API Key. API Key is unique for a specific user in a single project. The result will be imported for the project associated with the given API Key.

Format

selection

Yes

Format of result file to be imported. Supported formats:

cucumber/json testng/xml junit/xml QAF hpuft/xml specflow/json

File

string

Yes

Path to your result file to be uploaded.

Example : The Jenkins plugin is expecting the file in Jenkins Workspace. 
If your workspace name is WithoutSouceCode, then you will find a folder name with "WithoutSouceCode" in your installation directory like Jenkins/Home/workspace/WithoutSouceCode. 
Your result file should be under Jenkins/Home/workspace/WithoutSouceCode/Testng-result.xml. 
The path that should be set in plugin configuration is "/Testng-result.xml"

If your automation generates multiple result files of the supported format in a folder then provide the absolute path till the folder name(It should not be the path till workspace). QMetry plugin will zip all supported format files and upload them to QMetry.

Test Cycle To Reuse

stringNoKey of the test cycle to be reused.

Upload Screenshots

checkboxNoCheck to

Account Key of the current user for test case/test cycle.

Reporter

string

No

Account Key of the current user test case/test cycle.

Precondition (only for Test Case)

string

No

Precondition for test case.

Estimated Time (only for Test Case)

string

No

Estimated time for test case in ‘HH:mm’ format

Planned Start Date (only for Test Cycle)

string

No

Planned Start Date of test cycle in 'dd/MMM/yyyy HH:mm' format

Planned End Date (only for Test Cycle)

string

No

Planned End Date of test cycle in 'dd/MMM/yyyy HH:mm' format

Custom Fields

string

No

Comma separated custom fields in JSON array.


Server

In case of Server instance for QMetry for Jira, select the Server option and fill in the required data.


Image Added


Parameters for Server instance:


Parameter

Type

Required

Description

Jira URLstringYesEnter Jira URL.

Username

string

Yes

Jira Username.

Password

string

Yes

Password for Jira instance.

Automation API Key

string

Yes

Your API Key. API Key is unique for a specific user in a single project. The result will be imported for the project associated with the given API Key.

Format

selection

Yes

Format of result file to be imported. Supported formats:

cucumber/json testng/xml junit/xml QAF hpuft/xml specflow/json

File

string

Yes

Path to your result file to be uploaded.

Example : The Jenkins plugin is expecting the file in Jenkins Workspace. 
If your workspace name is WithoutSouceCode, then you will find a folder name with "WithoutSouceCode" in your installation directory like Jenkins/Home/workspace/WithoutSouceCode. 
Your result file should be under Jenkins/Home/workspace/WithoutSouceCode/Testng-result.xml. 
The path that should be set in plugin configuration is "/Testng-result.xml"

If your automation generates multiple result files of the supported format in a folder then provide the absolute path till the folder name(It should not be the path till workspace). QMetry plugin will zip all supported format files and upload them to QMetry.

Test Cycle To Reuse

stringNoKey of the test cycle to be reused.

Upload Screenshots

checkboxNoCheck to upload attachments in execution. Default value: false.

Environment

stringNoName of the environment on which test cycle has to be executed.
Build

string

NoName of the build for test cycle execution.



Test Case and Test Cycle Fields

Parameter

Type

Required

Description

Summary (

For

Code Snippet for Server: QMetry for Jira v4.0 and above

Pipeline Script

...

Syntax of format:

  • cucumber/json
  • testng/xml
  • junit/xml
  • QAF
  • hpuft/xml
  • specflow/json

Image Removed

Parameters for Cloud

...

Parameter

...

Type

...

Required

...

Description

...

API Key

...

string

...

Yes

...

Your API Key. API Key is unique for a specific user in a single project. The result will be imported for the project associated with the given API Key.

...

Format

...

selection

...

Yes

...

Format of result file to be imported. Supported formats:

cucumber/json testng/xml junit/xml QAF hpuft/xml specflow/json

...

File

...

string

...

Yes

...

Path to your result file to be uploaded.

Example : The Jenkins plugin is expecting the file in Jenkins Workspace. 
If your workspace name is WithoutSouceCode, then you will find a folder name with "WithoutSouceCode" in your installation directory like Jenkins/Home/workspace/WithoutSouceCode. 
Your result file should be under Jenkins/Home/workspace/WithoutSouceCode/Testng-result.xml. 
The path that should be set in plugin configuration is "/Testng-result.xml"

...

Test Cycle To Reuse

...

Upload Screenshots

...

Environment

...

Parameter

...

Type

...

Required

...

Description

...

Summary (For Test Cycle)

...

string

...

No

...

Summary of the test cycle.

...

Priority

...

string

...

No

...

Priority to be added to the test case/test cycle.

...

Custom Fields

...

Comma separated custom fields in JSON array.

Parameters for Server Instance

Parameter

Type

Required

Description

Jira URL

string

Yes

Enter Jira URL

Username

string

Yes

Jira Username.

Password

string

Yes

Password for Jira instance.

API Key

string

Yes

Your API Key. API Key is unique for a specific user in a single project. The result will be imported for the project associated with the given API Key.

Format

selection

Yes

Format of result file to be imported. Supported formats:

cucumber/json testng/xml junit/xml QAF hpuft/xml specflow/json

File

string

Yes

Path to your result file to be uploaded.

Example : The Jenkins plugin is expecting the file in Jenkins Workspace. 
If your workspace name is WithoutSouceCode, then you will find a folder name with "WithoutSouceCode" in your installation directory like Jenkins/Home/workspace/WithoutSouceCode. 
Your result file should be under Jenkins/Home/workspace/WithoutSouceCode/Testng-result.xml. 
The path that should be set in plugin configuration is "/Testng-result.xml"

Test Cycle To Reuse

stringNoKey of the test cycle to be reused.

Upload Screenshots

checkboxNoCheck to upload attachments in execution. Default value: false.

Environment

stringNoName of the environment on which test cycle has to be executed.BuildstringNoName of the build for test cycle execution.Test Case and Test Cycle Fields

Parameter

Type

Required

Description

Summary (For Test Cycle)

string

No

Summary of test cycle.

Priority

string

No

Priority

only for Test Cycle)

string

No

Summary of test cycle.

Description

string

No

Description of test case/test cycle

Priority

string

No

Priority to be added to the test case/test cycle.

Status

string

No

Status to be added to the test case/test cycle.

Components

string

No

Comma separated names of Components to be added to the test case/test cycle.

Labels

string

No

Comma separated names of Labels to be added to the test case/test cycle.

Fix Version Id (How to find the Fix Version Id)

number

No

Id of Fix Version to be added to the test case/test cycle.

Sprint Id (How to find the Sprint Id)

number

No

Id of Sprint to be added to the test case/test cycle.

Pipeline

QMetry Test Management supports Jenkins Pipeline for implementing and integrating continuous delivery pipelines into Jenkins.

Let’s create a standard Pipeline job in Jenkins.

1. To create a new Jenkins job, click on the New Item option on the Jenkins menu.

Image Removed

2. Provide a name for your job.

    Select Pipeline on the screen and then click OK.

Image Removed

3. Next, the configuration page appears where you can configure your job by various categories: General, Build Triggers, Advanced Project Options, and Pipeline.

Image Removed

4.  Optionally, you can set Build Triggers.

Select the Build Triggers tab. Let’s just add a periodic trigger which triggers build every minute – every hour – every day (Schedule: * * * * *).

Image Removed

5. Advanced Project Options: This is optional. You can give Display Name which will replace the name you gave earlier to the Pipeline project.

Image Removed

6. Jenkins works as a bridge between QMetry Test Management and automation frameworks. To publish results in QMetry, provide a Pipeline script.

Enter Pipeline script to define your code repository, generate test results and upload test results into QMetry Test Management.

Code Snippet for Cloud: QMetry for Jira v4.0 and above

Pipeline Script

...

stage('Upload Result to QTM4J cloud V4'){ step([$class: 'TestReportDeployPublisherCloudV4', testToRun: 'CLOUD', apikey: 'a518c3dd80791930bb0045eae80421cafe3378a7bbcb315092d127df5b111673853e8f29350552cf8a82a8fba7ff6cb556f6ea1c70d38151ab806f0d4e2771c230dd12edde1783a40a2d4165b70f8369', format: 'cucumber/json', file: 'cucumber', testCycleToReuse: "", testCycleLabels: "v8.2.1", testCycleComponents: "FitBit", testCyclePriority: "High", testCycleStatus: "To Do", testCycleSummary: "Basic mode testing", testCycleCustomFields: "[{"name": "Country", "value": "India"}, {"name": "Language", "value": "English"}, {"name": "TimeZone", "value": "IST"}]", testCaseLabels: "v8.2.1", testCaseComponents: "FitBit", testCasePriority: "High", testCaseStatus: "To Do", testCaseCustomFields: "[{"name": "Country", "value": "India"}, {"name": "Language", "value": "English"}, {"name": "TimeZone", "value": "IST"}]"]) }

Assignee

string

No

Account Key of the current user for test case/test cycle.

Reporter

string

No

Account Key of the current user test case/test cycle.

Estimated Time (only for Test Case)

string

No

Estimated time for test case in ‘HH:mm’ format

Planned Start Date (only for Test Cycle)

string

No

Planned Start Date of test cycle in 'dd/MMM/yyyy HH:mm' format

Planned End Date (only for Test Cycle)

string

No

Planned End Date of test cycle in 'dd/MMM/yyyy HH:mm' format

Custom Fields

array

No

Comma separated custom fields in JSON array.


Pipeline

QMetry Test Management supports Jenkins Pipeline for implementing and integrating continuous delivery pipelines into Jenkins.

Let’s create a standard Pipeline job in Jenkins.


1. To create a new Jenkins job, click on the New Item option on the Jenkins menu.

Image Added


2. Provide a name for your job.

    Select Pipeline on the screen and then click OK.


Image Added


3. Next, the configuration page appears where you can configure your job by various categories: General, Build Triggers, Advanced Project Options, and Pipeline.


Image Added


4.  Optionally, you can set Build Triggers.

Select the Build Triggers tab. Let’s just add a periodic trigger which triggers build every minute – every hour – every day (Schedule: * * * * *).


Image Added


5. Advanced Project Options: This is optional. You can give Display Name which will replace the name you gave earlier to the Pipeline project.


Image Added


6. Jenkins works as a bridge between QMetry Test Management and automation frameworks. To publish results in QMetry, provide a Pipeline script.

Enter Pipeline script to define your code repository, generate test results and upload test results into QMetry Test Management.


Code Snippet for Cloud: QMetry for Jira v4.0 and above

Pipeline Script


stage('Upload Result to QTM4J cloud V4'){ step([$class: 'TestReportDeployPublisherCloudV4', testToRun: 'CLOUD', apikey: 'a518c3dd80791930bb0045eae80421cafe3378a7bbcb315092d127df5b111673853e8f29350552cf8a82a8fba7ff6cb556f6ea1c70d38151ab806f0d4e2771c230dd12edde1783a40a2d4165b70f8369', format: 'cucumber/json', file: 'cucumber.json', testCycleToReuse: "", environment: "Firefox", build: "1.0.0", attachFile: true, testCycleSummary: "Basic mode testing", testCycleDescription: "Unit testing", testCycleLabels: "v8.2.1", testCycleComponents: "FitBit", testCyclePriority: "High", testCycleStatus: "To Do", testCycleSprintId: "10", testCycleFixVersionId: "10300", testCycleAssignee: "5caaf8b3307b0637cbbdb03c", testCycleReporter: "5caaf8b3307b0637cbbdb03c", testCycleStartDate: "15/May/2020 00:00", testCycleEndDate: "30/May/2020 00:00", testCycleCustomFields: "[{"name": "Country", "value": "India"}, {"name": "Language", "value": "English"}, {"name": "TimeZone", "value": "IST"}]", testCaseDescription: "Verify the login page", testCasePrecondition: "Login with valid user details", testCaseLabels: "v8.2.1", testCaseComponents: "FitBit", testCasePriority: "High", testCaseStatus: "To Do", testCaseSprintId: "10", testCaseFixVersionId: "10300", testCaseAssignee: "5caaf8b3307b0637cbbdb03c", testCaseReporter:"5caaf8b3307b0637cbbdb03c", testCaseEstimatedTime: "10:10", testCaseCustomFields: "[{"name": "Country", "value": "India"}, {"name": "Language", "value": "English"}, {"name": "TimeZone", "value": "IST"}]"])}



Code Snippet for Server: QMetry for Jira v4.0 and above

Pipeline Script

stage('Upload Result to QTM4J server V4'){ step([$class: 'TestReportDeployPublisherCloudV4', jiraUrlServer: 'http://qtm4jpostgres.qmetry.com:8080/', username: 'admin', password: hudson.util.Secret.fromString('john123#'), testToRun: 'SERVER', apikeyServer: 'bc851b65c42259f4984f36d9e5f8931327b4985d1a68d9e8', formatServer: 'junit/xml', fileServer: 'junit.xml', testCycleToReuseServer: "", attachFileServer: true, environmentServer: "Firefox", buildServer: "1.0.0", testCycleSummaryServer: "Basic mode testing", testCycleDescriptionServer: "Unit testing", testCycleLabelsServer: "v8.2.1", testCycleComponentsServer: "FitBit", testCyclePriorityServer: "High", testCycleStatusServer: "To Do", testCycleSprintIdServer: "63", testCycleFixVersionIdServer: "10909", testCycleAssigneeServer: "JIRAUSER11200", testCycleReporterServer: "JIRAUSER11200", testCycleStartDateServer: "15/May/2020 00:00", testCycleEndDateServer: "30/May/2020 00:00", testCycleCustomFieldsServer: "[{"name": "Country", "value": "India"}, {"name": "Language", "value": "English"}, {"name": "TimeZone", "value": "IST"}]", testCaseDescriptionServer: "Verify the login page", testCaseLabelsServer: "v8.2.1", testCaseComponentsServer: "FitBit", testCasePriorityServer: "High", testCaseStatusServer: "To Do", testCaseSprintIdServer: "63", testCaseFixVersionIdServer: "10910", testCaseAssigneeServer: "JIRAUSER11200", testCaseReporterServer:"JIRAUSER11200", testCaseEstimatedTimeServer: "10:10", testCaseCustomFieldsServer: "[{"name": "Country", "value": "India"}, {"name": "Language", "value": "English"}, {"name": "TimeZone", "value": "IST"}]"])}



Syntax of format:

  • cucumber/json
  • testng/xml
  • junit/xml
  • QAF
  • hpuft/xml
  • specflow/json


Image Added


Parameters for Cloud


Parameter

Type

Required

Description

API Key

string

Yes

Your API Key. API Key is unique for a specific user in a single project. The result will be imported for the project associated with the given API Key.

Format

selection

Yes

Format of result file to be imported. Supported formats:

cucumber/json testng/xml junit/xml QAF hpuft/xml specflow/json

File

string

Yes

Path to your result file to be uploaded.

Example : The Jenkins plugin is expecting the file in Jenkins Workspace. 
If your workspace name is WithoutSouceCode, then you will find a folder name with "WithoutSouceCode" in your installation directory like Jenkins/Home/workspace/WithoutSouceCode. 
Your result file should be under Jenkins/Home/workspace/WithoutSouceCode/Testng-result.xml. 
The path that should be set in plugin configuration is "/Testng-result.xml"

Test Cycle To Reuse

stringNoKey of the test cycle to be reused.

Upload Screenshots

checkboxNoCheck to upload attachments in execution. Default value: false.

Environment

stringNoName of the environment on which the test cycle has to be executed.
BuildstringNoName of the build for test cycle execution.



Test Case and Test Cycle Fields

Parameter

Type

Required

Description

Summary (only for Test Cycle)

string

No

Summary of test cycle.

Description

string

No

Description of test case/test cycle.

Priority

string

No

Priority to be added to the test case/test cycle.

Status

string

No

Status to be added to the test case/test cycle.

Components

string

No

Comma separated names of Components to be added to the test case/test cycle.

Labels

string

No

Comma separated names of Labels to be added to the test case/test cycle.

Fix Version Id (How to find the Fix Version Id)

number

No

Id of Fix Version to be added to the test case/test cycle.

Sprint Id (How to find the Sprint Id)

number

No

Id of Sprint to be added to the test case/test cycle.

Assignee

string

No

Account Key of the current user for test case/test cycle.

Reporter

string

No

Account Key of the current user test case/test cycle.

Precondition (only for Test Case)

string

No

Precondition for test case.

Estimated Time (only for Test Case)

string

No

Estimated time for test case in ‘HH:mm’ format

Planned Start Date (only for Test Cycle)

string

No

Planned Start Date of test cycle in 'dd/MMM/yyyy HH:mm' format.

Planned End Date (only for Test Cycle)

string

No

Planned End Date of test cycle in 'dd/MMM/yyyy HH:mm' format.

Custom Fields

string

No

Comma separated custom fields in JSON array.



Parameters for Server Instance


Parameter

Type

Required

Description

Jira URL

string

Yes

Enter Jira URL

Username

string

Yes

Jira Username.

Password

string

Yes

Password for Jira instance.

API Key

string

Yes

Your API Key. API Key is unique for a specific user in a single project. The result will be imported for the project associated with the given API Key.

Format

selection

Yes

Format of result file to be imported. Supported formats:

cucumber/json testng/xml junit/xml QAF hpuft/xml specflow/json

File

string

Yes

Path to your result file to be uploaded.

Example : The Jenkins plugin is expecting the file in Jenkins Workspace. 
If your workspace name is WithoutSouceCode, then you will find a folder name with "WithoutSouceCode" in your installation directory like Jenkins/Home/workspace/WithoutSouceCode. 
Your result file should be under Jenkins/Home/workspace/WithoutSouceCode/Testng-result.xml. 
The path that should be set in plugin configuration is "/Testng-result.xml"

Test Cycle To Reuse

stringNoKey of the test cycle to be reused.

Upload Screenshots

checkboxNoCheck to upload attachments in execution. Default value: false.

Environment

stringNoName of the environment on which test cycle has to be executed.
BuildstringNoName of the build for test cycle execution.


Test Case and Test Cycle Fields

Parameter

Type

Required

Description

Summary (only for Test Cycle)

string

No

Summary of test cycle.

Description

string

No

Description of test case/test cycle.

Priority

string

No

Priority to be added to the test case/test cycle.

Status

string

No

Status to be added to the test case/test cycle.

Components

string

No

Comma separated names of Components to be added to the test case/test cycle.

Labels

string

No

Comma separated names of Labels to be added to the test case/test cycle.

Fix Version Id (How to find the Fix Version Id)

number

No

Id of Fix Version to be added to the test case/test cycle.

Sprint Id (How to find the Sprint Id)

number

No

Id of Sprint to be added to the test case/test cycle.

StatusComponents

Assignee

string

No

Status to be added to the test run.

Account Key of the current user for test case/test cycle.

Reporter

string

No

Comma separated names of Components to be added to the test case/test cycle.Labels

Account Key of the current user test case/test cycle.

Estimated Time (only for Test Case)

string

No

Estimated time for test case in ‘HH:mm’ format

Planned Start Date (only for Test Cycle)

string

No

Comma separated names of Labels to be added to the test case/test cycle.Fix Version Id (How to find the Fix Version Id)numberNoId of Fix Version to be added to the test case/test cycle.Sprint Id (How to find the Sprint Id)numberNoId of Sprint to be added to the test case/test cycle

Planned Start Date of test cycle in 'dd/MMM/yyyy HH:mm' format

Planned End Date (only for Test Cycle)

string

No

Planned End Date of test cycle in 'dd/MMM/yyyy HH:mm' format

Custom Fields

string

No

Comma separated custom fields in JSON array.



7. On successful completion of the process, you can see the console output. It displays a success message for uploading the result file.

...