Versions Compared

Key

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


Table of Contents

...

Supported file types : JSON

Sample Test Result File

Click Click here to download a sample file.


Image RemovedImage Added

Reuse existing Test cases and Requirements

While importing test result file, if you want to reuse Test Case and Requirements here are the annotations that need to be provided in the feature file. 


KeywordDescription
@testEntityKey
  • If the executed test steps match with the steps and summary of

latest
  • any version of the existing test case, then the existing test case version (i.e. testEntityKey) will be

updated
  • reused.

  • If the executed test steps do not match with the steps of

latest
  • any version of the existing test case, then a new version of the test case (i.e. testEntityKey) will be created.

  • In the absence of the defined test case key (i.e.

testEntityKey), a new
  •  testEntityKey):

    • If the testcase and all of the test steps from the result file match with the summary and test steps of any version of the existing test case, then the existing test case version will be reused.

    • If only testcase summary matches then a new version of test case will be created of matched test case.

    • If testcase summary and steps both don’t match then a new test case will be created.

  • Multiple test case keys (i.e. testEntityKeys) can be defined for a single scenario, which will update/create multiple test cases for that single scenario and link these test cases with an automated test suite.

  • When an invalid/archived test case entity is passed through the result json file:

    • If the executed test steps match with the steps and summary of any version of the existing test case, then the existing test case version will be reused.

    • If the executed test steps does not match with the steps and summary of any version of the existing test case, then a new test case will be created using that element.

@requirementKeyCreated/Linked Test Case will be linked to Requirement Key

The Description value in the result file for the Cucumber framework will be imported into QMetry as Test Case Description when a new version of a test case is created. If the test case description is available in file and also passed in the testcase_fields parameter, then priority will be given to the Description value in the file.


Note: In scenarios where a manual test case is reused, the test case result will be updated. The test case version will increase by 1 due to changes in test steps. This particular test case version will be automated test case. The earlier version of the test case will remain manual.

...

Code Block
Feature: Banking
As a user
I want to make an ATM Transaction
 
@requirementKey=AP-RQ-1
@testEntityKey=AP-TC-28
@testEntityKey=AP-TC-32
@testEntityKey=AP-TC-37
Scenario: Withdraw less money
	Scenario to withdraw less money and verify
Given I have $1200 on my account
When I withdraw $600
Then I get $600 from the ATM
 
@requirementKey=AP-RQ-1
@testEntityKey=AP-TC-27
Scenario: Withdraw more money
	Scenario to withdraw more money and verify
Given I have $150 on my account
When I withdraw $300
Then I get $0 from the ATM
 
@requirementKey=AP-RQ-1
@testEntityKey=AP-TC-26
Scenario Outline: Withdraw money from the account
	Scenario to withdraw money
Given I have $<balance> on my account
When I withdraw $<withdraw>
Then I get $<received> from the ATM
 


Import Execution Attachments

Testers want to import a Cucumber result file into QMetry by scheduling automation for the test suite using the Maven framework. During this test case creation and import of results, they also want to attach screenshots/attachments for the failed results during the automation. The attachments will be shown at the test case level on the execution screen.

To add attachments in test run execution, you need to capture the log file and screenshots during the execution of automation testing. The attachment file should be base64 encoded with mime_type in the embedding tag of the report file.

...