https://cypress.io logo
FormData with File
# i-need-help
s
I've got a test where I'm uploading a file, but when I try to assert on the request, I'm getting an empty JSON object. I looked at the actual network request, and it is posting fine as
form/multipart
but because it has binary data included in a field, the entire request doesn't seem to be presenting well in Cypress. How do I either parse the request so that I can assert on the
multipart
text or work around this somehow? Using Cypress 12.2.0, working with React and e2e tests. I've tested the flow outside of Cypress and everything works as expected.
In Cypress, it looks like the request is empty: "assert expected {} to match /testimage.png/"