Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.

Update_plan_etry API does not allow adding new test cases?



I’m using TestRail APIs as part of our automation script at the moment.
The way that we are setting this up is that we create a test plan, and add plan entries based on the configuration.
However, I am experiencing the issue on adding new test cases into existing test plan entries.

Does TestRail API allow us to dynamically add new test cases into test run inside test plan?



Hi James,

Thanks for your posting. Yes, update_plan_entry also lets you update the case selection but only for the entire plan entry. If you have overridden the selection for the runs insides the entry (e.g. configurations), then the case selection on the entry level wouldn’t apply and wouldn’t be updated. Do you use configurations with add_plan/add_plan_entry?



Hi Tobias ,
i have the exact problem {using the Test Rail API}
i have a Test run with 3 configurations
e.g. 600 , 700 ,800
each configurations ive associated with the proper TC’s
now i want to do Update Plan Entry
to add from the API TC’s for a specific configuration
how can i do that?



Hi roller,

Thank you for posting! It is not currently possible to update the case selection for an individual test run within a test plan entry using the TestRail API. As Tobias mentioned, the update_plan_entry method would only support updating the case selection for the entire plan entry and any individual test runs within the plan entry that override this case selection would not be updated. We are happy to review adding support for this in a future update and I have added your vote to our feature request for this. That said, we don’t have a specific timeframe/ETA to provide for this yet. In the meantime, you can change the case selection for the individual test runs from the TestRail UI.

I hope this helps!