I have a POST request with file upload in it. I am using newman on a linux server and run my tests via Jenkins. In the Jenkins job I specify the that the postman json file is in a git repo. My files to be uploaded are also in the same git repo. How do I specify the path, in the Postman json (“src:…”) to such a file residing in the git repo? The newman command in Jenkins understands that the json file is in the git repo, but apparently the execution of “src:…” path inside the json file does not.
newman run ACAP/postman/acapNewAPI.postman_collection.json…
Here the path to where in the git repo the json file is located is working fine. So why does it not work with specifying:
“src”: “ACAP/postman/testfile.test” or “./ACAP/postman/testfile.test”
I get “no such file” from the Jenkins run
Have you tried using this flag, on the Newman run command:
`--working-dir <path>` Set the path of the working directory to use while reading files with relative paths. Default to current directory.