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

BulkUpdation if one caseid missing

I have a case where am using add_results_for_case method for bulk updation.
I found some cases where
1)Say I have 100 case ID to update from our list(at our end).
in which 2 or 3 are found are found missing at tesrun section at test rail–(could be some one removed some test cases which are no long necessary just an example to say)

If I update it will say caseid not found.

Could you please tell me a way where I can handle this case where I want my results to get updated for 99 cases and to the one which is not there ,returns exception for that particular case alone.Currently results won’t get updated for a single case if one doesn’t exist

Hi @Sreekumar,
are you really using add_results_for_case and Not add_results_for_cases?

So, if you expect a defined set of tests to get results added, why not check if the tests really exist before to try the add? Use get_tests to check for the instances first and remove the not existing test results and probably log the fact.


I am using add_results_for_cases.
Thanks for the info Karsten.Let me get the tests using get_tests