The data should not get updated and I should get file payload as JSON string or I should be able to pass the fileContent by parsing the JSON object using JSON.stringfy(fileData) as we are doing earlier (before https://github.com/abramenal/cypress-file-upload/issues/175).
I should get payload data as
{"key1":"value1","key2":"value2","key3":"value3","key4":"value4"}
Steps to reproduce: (app code and test code)
Try to attach a JSON file to a Dropzone component which reads the file:
Current behavior:
When I upload a JSON file. The file payload I get is malformed. It should be formatted JSON file and not double stringified JSON string.
File content
{"key1":"value1","key2":"value2","key3":"value3","key4":"value4"}
After uploading the file using
attachFile
I am getting file payload as -Output
Desired behavior:
The data should not get updated and I should get file payload as JSON string or I should be able to pass the fileContent by parsing the JSON object using JSON.stringfy(fileData) as we are doing earlier (before https://github.com/abramenal/cypress-file-upload/issues/175).
I should get payload data as
{"key1":"value1","key2":"value2","key3":"value3","key4":"value4"}
Steps to reproduce: (app code and test code)
or I also tried to read the file using