Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uploading PSD file with Cypress #17021

Closed
yasinitskyi opened this issue Jun 20, 2021 · 2 comments
Closed

Uploading PSD file with Cypress #17021

yasinitskyi opened this issue Jun 20, 2021 · 2 comments
Labels
stale no activity on this issue for a long period

Comments

@yasinitskyi
Copy link

yasinitskyi commented Jun 20, 2021

I need to upload PSD file with cypress. Our drangNdrop input is customized (written from scratch). You can see how it looks like in our React app:
image
There is openFilePrompt function which is triggering via onClick listener on the dragNdrop area, it looks like this in the code:
image
Since it is creating input in the DOM inside the body tag, so I am trying to insert my PSD file directly to that input without triggering onDrop function which is called just after the mention openFilePrompt, I am using cypress-upload-file plugin in this example, my code looks like this:
image
I am converting it to the Blob and then attaching it directly to fresh input which has been created by clicking on dragNdrop tag.
The error I am getting:
image
The error is the same if I am passing this file without converting it to the Blob.
I also tried to create a custom upload function where I was triggering onDrop function, in the code:
image
Error:
image
I looked up at this issue abramenal/cypress-file-upload#70 and added 'base64' for fixture as well, and now I do not get any error, however my payload (which is PSD) is empty:
image
My code:
image
image

@cypress-app-bot
Copy link
Collaborator

This issue has not had any activity in 180 days. Cypress evolves quickly and the reported behavior should be tested on the latest version of Cypress to verify the behavior is still occurring. It will be closed in 14 days if no updates are provided.

@cypress-app-bot cypress-app-bot added the stale no activity on this issue for a long period label May 17, 2023
@cypress-app-bot
Copy link
Collaborator

This issue has been closed due to inactivity.

@cypress-app-bot cypress-app-bot closed this as not planned Won't fix, can't repro, duplicate, stale Jun 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale no activity on this issue for a long period
Projects
None yet
Development

No branches or pull requests

2 participants