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

TestRail error "Field :results.elapsed is a required field"

I completed all the integration for Newman with TestRail
After I run my postman/newman collection the TestRail API throw err

As a result my tests appear as ‘Untested’ in the test run
How to handle this? Nothing found in topics.

Thx

Hi,
did you check if the field is set “required” in the admin console?
Sorry, silly question, but usually the first check…

Karsten

Hi, thx for response
Yes. Fields of results and elapsed time are set as required.
Well, then it sounds that I need to disable them?
or is there another way to send their values?
I just run my tests within newman locally.

Hi,
as usual two choices:

  1. Disable it, but if somebody really wants to have it, e.g. for estimation reasons (on the manual testing side usually) probably not the correct solution.
  2. Pass the value, either the correct or a dummy, on adding the results.

That depends on your usage of TestRail.

For passing the value for elapsed time check the endpoint doc for add_results_for_cases. Which is the same for add_result_for_case. Check the field list or the example. That’s it. :grinning:

Karsten

So, if I use the “newman-reporter-testrail” I need to make code changes in this node module?
Sorry for such questions, this is my first attempt to automatically create Test Runs & Results in TestRail after running my Postman API tests with Newman

Thx

Sorry, I didn’t realize it is an available package.

I took a quick look at the doc. It seems it is limited to the ‘basic’ functionality of create/update of a run with results for the tests.

I miss the ability to use test plans or to add further information for a result, like the elapsed time (or attachments, comments etc.). If an additional info is required it seems to be impossible to add and the solution will fail (just a quick look).

Probably you should check any discussion for the reporter itself, if there is a mechnism to enrich it somehow. Otherwise you need to make the code changes.

For now, Option 1 would help you.

Check this post…