Weird Results - Content-Length Header is NOT appearing but is generated in Postman
Hi,
I have a GET request that retrieves a .csv file if I add '_format=csv' as query parameter on my request.
e.g.
/api/1/{namespace}/{dataset}?_format=csv
I need to assert that the generated response returns a 'Content-Length' HTTP header as well as others.
For some reason the 'Content-Length' header is NOT being generated in the headers even though the others are e.g. if I create an HTTP Header existence assertion for 'Content-Length' the assertion fails.
If I run exactly the same request in Postman - the Content-Length header is generated fine.
I'm pretty sure the problem is due to the fact that ReadyAPI! is trying to render the payload (the .csv content)
I've attached 3 images of the results - the RAW, the Outline and the XML (there is no output in the json tab).
Despite the fact that there appears to be a contentLength attribute in the Outline - if I try and assert on it or any of the 3 attributes in the Outline - I get a warning dialogue 'No match found in the current response'
If you look at the XML tab- you can see a contentLength attribute is displayed.
I know altering the prettyprint checkbox in the WSDL section does alter some of the rendering in the output (it inserts CDATA wrappers into dodgy xml) - but this isn't working.
Essentially I just need to assert the Content-Length header is present - and there's currently no way to do this in ReadyAPI that I can tell - although I can see the header in postman fine.
Is anyone very familiar with the display settings in ReadyAPI! that may help?
Thanks to all!
richie
I'm wondering if there is a display/rendering option that I can alter - so that the