Manual Test Passing but failing in Collection Runner

Hi. I have a post api that uploads a document.
When i run it manually the tests pass but when i run it in the collection runner it fails and gives 500 internal server error.I am setting the environment to be correct on the collection runner and i have saved. Please looking for assistance.Thanks

Hi there.

Seems you are executing a request with a file. Have you included this file into the collection runner?

Welcome to the community, @vikash.chetty! :wave:

The fix is easy, but not very obvious.

If you open up Postman settings (ctrl + ,) and scroll down down the Working Directory section and look at the folder in the Location field.

You need to put the file you’re uploading in that directory, that way Postman knows where to pull it from when using the collection runner.

1 Like

I am facing the same problem. Placing a file into the working directory did not solve the problem for me.
There seems to be multiple users having the same problem as there are many related postings on this issue and no real clear answer - other than putting the file in the working directory - and that unfortunately does not work.
I have seen some comments that you have to use something called Newman to successfully upload files but no good clear directions on how that is accomplished.
Any help would be appreciated.

How are you adding files in the postman request?

Hi Allen, I am using the POST body - where I specify File in the Key column and then select the file from the drop down in the Value column.
Works fine in the main postman work area - but not when used in the Runner.