Searching for tests
The advanced search functionality of JIRA allows to use structured queries to search for issues. These queries are written in Atlassian's JIRA Query Language (JQL). The result set is displayed as a list of issues in the issue navigator. It is also possible to save advanced search queries for private or public use.
Test for JIRA enhances the advanced search of JIRA with new functions to search for issues in T4J specific entities such as test plans or definition trees.
Saved JQL queries can be further used for filtering or adding issues matching the query to a definition tree.
How to search for tests
- Select Issues > Search for Issues from the main navigation bar
- Switch to advanced searching by clicking the Advanced link from the filter bar
- Enter a query in the search text box
- Click on the Search button or hit enter to execute the query
The query should be of the following structure: field operator function()
You can look up the supported fields and operators for the new Requirements for JIRA functions in the function reference below.
Function Reference
Test Definition Folder
Returns the issues/tests that are contained in a specific folder in the definition tree of a project.
Syntax
testDefinitionFolder(path)
Where path represents a part of the hierarchical structure of the definition tree.
Path should be of the following form: "project name/parentFolder/.../childFolder"
Supported Fields
Supported Operators
= | != | ~ | !~ | > | >= | < | <= | IS | IS NOT | IN | NOT IN | WAS | WAS IN | WAS NOT | WAS NOT IN | CHANGED |
Examples
Find all issues that are contained in the folder "Webtests" within the definition tree of the project "OnlineHotelReservation:
issue in testDefinitionFolder("OnlineHotelReservation/Webtests")
Test Definition Path
Returns the issues/tests that are contained in a specific folder in the definition tree of a project.
Also returns the issues/tests of subsequent folders.
Syntax
testDefinitionPath(path)
Where path represents a part of the hierarchical structure of the definition tree.
Path should be of the following form: "project name/parentFolder/.../childFolder"
Supported Fields
Supported Operators
= | != | ~ | !~ | > | >= | < | <= | IS | IS NOT | IN | NOT IN | WAS | WAS IN | WAS NOT | WAS NOT IN | CHANGED |
Examples
Find all issues that are contained in the folder "Webtests" or one of its subfolders within the project "OnlineHotelReservation:
issue in testDefinitionPath("OnlineHotelReservation/Webtests")
Test Plan
Returns all issues/tests that are part of a specific test plan.
Syntax
testPlan(project,plan)
Where project is the name of the project that contains the desired test plan and plan is the name of the test plan.
Supported Fields
Supported Operators
= | != | ~ | !~ | > | >= | < | <= | IS | IS NOT | IN | NOT IN | WAS | WAS IN | WAS NOT | WAS NOT IN | CHANGED |
Examples
Find all issues/tests that are part of the test plan "Example Plan" on the project "OnlineHotelReservation"
issue in testPlan("OnlineHotelReservation","Example Plan")
Find all issues/tests that are part of the test plan "Example Plan" regardless of project
issue in testPlan("","Example Plan")
Find all issues/tests in project "OnlineHotelReservation" not yet part of any test plan
issue in testPlan("OnlineHotelReservation","")
Find all issues/tests in all project not yet part of any test plan
issue in testPlan("","")
Failed in Execution
Returns all issues/tests that are marked as failed in a specific execution of a given test plan.
Syntax
failedInExecution(project,plan,execution)
Where project is the name of the project that contains the desired test plan.
Plan is the name of the test plan.
Execution is the name of a specific execution of the given test plan.
Supported Fields
Supported Operators
= | != | ~ | !~ | > | >= | < | <= | IS | IS NOT | IN | NOT IN | WAS | WAS IN | WAS NOT | WAS NOT IN | CHANGED |
Examples
Find all issues/tests that are part of the test plan "Example Plan" created on the project "OnlineHotelReservation", which were marked as failed during "Test Execution":
issue in failedInExecution("OnlineHotelReservation","Example Plan","Test Execution")