As an alternative to Run automated tests operation in Test Plan it is also possible to use automatic job execution, e.g. after changes in code repository are pushed. This approach however requires specifying default parameters in the plugin configuration and created Test Plan in Jira.
Jenkins
Steps
To run automated tests from Jenkins as a part of the CI process:
In the configured parameters fill in the following values in Default Value:
testPlanKey - the key of the previously created Test Plan, on which Test Cases will be created based on tests from the selected job.
targetIteration - tells whether to add Test Cases to current iteration in Test Plan or to create new in Test Plan. You can use these options:
CURRENT_ITERATION
NEW_ITERATION
testCaseCreationStrategy - tells whether new Test Cases should be created with test results, or only limited to updating existing Test Cases in Test Plan. You can use these options:
CREATE_AND_UPDATE
UPDATE_EXISTING
Click Save.
Build a job with specified parameters.
Result
The Test Cases will be created in the Test Plan with the appropriate test names and statuses.
Note
Remember to refresh the Test Plan view to see Test Cases after you have finished running the tests on the CI Server.
Bamboo
Steps
To run automated tests from Bamboo as a part of the CI process:
Select the job in the Stages tab where the TestFLO - Test results publisher task was added.
Select the task and fill the parameters with the following values:
testPlanKey - the key of the previously created Test Plan, on which Test Cases will be created based on tests from the selected job.
targetIteration - tells whether to add Test Cases to current iteration in Test Plan or to create new in Test Plan. You can use these options:
CURRENT_ITERATION
NEW_ITERATION
testCaseCreationStrategy - tells whether new Test Cases should be created with test results, or only limited to updating existing Test Cases in Test Plan. You can use these options:
CREATE_AND_UPDATE
UPDATE_EXISTING
Click Save.
Run plan with specified parameters.
Result
The Test Cases will be created in the Test Plan with the appropriate test names and statuses.
Note
Remember to refresh the Test Plan view to see Test Cases after you have finished running the tests on the CI Server.
Running tests directly from CI Server manually
Another alternative to Run automated tests operation in Test Plan you can run tests directly from CI Server manually. This operation will require you to create a Test Plan in Jira first and provide the required parameters in the selected job/build plan.
Jenkins
Steps
To run automated tests directly from Jenkins manually:
testPlanKey - the key of the created Test Plan, on which Test Cases will be created based on tests from the selected job.
targetIteration - tells whether to add Test Cases to current iteration in Test Plan or to create new in Test Plan. You can use these options:
CURRENT_ITERATION
NEW_ITERATION
testCaseCreationStrategy - tells whether new Test Cases should be created with test results, or only limited to updating existing Test Cases in Test Plan. You can use these options:
CREATE_AND_UPDATE
UPDATE_EXISTING
Click Build to build a job with specified parameters.
Result
The Test Cases will be created in the Test Plan with the appropriate test names and statuses.
Note
Remember to refresh the Test Plan view to see Test Cases after you have finished running the tests on the CI Server.
Bamboo
Steps
To run automated tests directly from Bamboo manually:
Add Variable name and fill Value using the following options:
testPlanKey - the key of the created Test Plan, on which Test Cases will be created based on tests from the selected job.
targetIteration - tells whether to add Test Cases to current iteration in Test Plan or to create new in Test Plan. You can use these options:
CURRENT_ITERATION
NEW_ITERATION
testCaseCreationStrategy - tells whether new Test Cases should be created with test results, or only limited to updating existing Test Cases in Test Plan. You can use these options:
CREATE_AND_UPDATE
UPDATE_EXISTING
Click Run plan to build a plan with specified variables.
Result
The Test Cases will be created in the Test Plan with the appropriate test names and statuses.
Note
Remember to refresh the Test Plan view to see Test Cases after you have finished running the tests on the CI Server.