In this feature video, learn how to trigger a test execution through an API.
Generate and Publish your Test Cases into a Test Plan
Inside a model, generate your test cases by navigating to Scenarios, clicking Run, and selecting the Options button next to Automation Code.
Under the Publish tab, there is an option to publish the test cases into a Test Plan. In this example, we will be publishing our tests into a regression test plan.
On the Modeller Homepage, navigate to Tests → Test Plan to view your test plans.
After selecting a plan, you are taken to the Test Suite page. Here you can see the test cases that have been published to the plan, as well as their results. We can publish test cases from many different models in one single plan.
Execute Test Plan via an API Request
Under the Actions button, there is an option to Embed in Pipeline. This will show us the instructions to instrument the Test Suite execution via an API request.
We can select the relevant API request and submit it through any tool that can submit API calls (in our example, we are using Postman).
We use the Job ID that was generated to query and track the status, as well as retrieve the results.
View Job Execution inside Test Modeller
Back inside Test Modeller, we can see that a new job has been created. This will trigger the creation and execution of the test cases that were part of the Test Plan.