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

The change event shouldn't be raised on an upload input if the value wasn't changed after setFilesToUpload #1844

Closed
dmitry-kurmanov opened this issue Nov 3, 2016 · 2 comments
Assignees
Labels
AREA: client STATE: Auto-locked Issues that were automatically locked by the Lock bot SYSTEM: upload TYPE: bug
Milestone

Comments

@dmitry-kurmanov
Copy link

I guess we have a different behaviour between testcafe's setFilesToUpload and browser users.

If we try to use setFilesToUpload to upload same file as before, then input[type=file] will updates. But if we try to do it "by hand" it will not updates. It is native behavior.

You can check it in my repo: https://github.com/dmitrykurmanov/surveyjs_testcafe
cli command: testcafe chrome tests/questions/file.js -T "setFilesToUpload_issue"

This test must be fail, but it is not.

Steps to reproduce native behaviour "by hand":

  1. choose big file ../resources/big_Dashka.jpg
  2. click "change_file_max_size" button
  3. choose same file
  4. see that error message is here and there is no preview, but by testcafe's setFilesToUpload this is not true
@AndreyBelym
Copy link
Contributor

We do not check if the value of file input is actually changed. Chrome do not raise change event if the currently selected file was chosen again. We raise change event every time, even if the new file is the already selected file.

@AndreyBelym AndreyBelym self-assigned this Nov 3, 2016
@AlexanderMoskovkin AlexanderMoskovkin changed the title setFilesToUpload behaviour The change event shouldn't be raised on an upload input if the value wasn't changed after setFilesToUpload Jun 9, 2017
@AndreyBelym AndreyBelym transferred this issue from DevExpress/testcafe Nov 22, 2018
@LavrovArtem LavrovArtem added this to the Planned milestone Nov 22, 2018
@miherlosev miherlosev modified the milestones: Planned, Sprint #24 Dec 17, 2018
@LavrovArtem LavrovArtem modified the milestones: Sprint #24, Sprint #25 Jan 10, 2019
@LavrovArtem LavrovArtem modified the milestones: Sprint #25, Sprint #26 Jan 22, 2019
@LavrovArtem LavrovArtem modified the milestones: Sprint #26, Sprint #27 Feb 6, 2019
@LavrovArtem LavrovArtem modified the milestones: Sprint #27, Sprint #28 Feb 15, 2019
@LavrovArtem LavrovArtem modified the milestones: Sprint #28, Sprint #29 Mar 13, 2019
@LavrovArtem LavrovArtem modified the milestones: Sprint #29, Sprint #30 Mar 21, 2019
@LavrovArtem LavrovArtem modified the milestones: Sprint #30, Sprint #31 Apr 2, 2019
@lock
Copy link

lock bot commented Apr 22, 2019

This thread has been automatically locked since it is closed and there has not been any recent activity. Please open a new issue for related bugs or feature requests. We recommend you ask TestCafe API, usage and configuration inquiries on StackOverflow.

@lock lock bot added the STATE: Auto-locked Issues that were automatically locked by the Lock bot label Apr 22, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Apr 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
AREA: client STATE: Auto-locked Issues that were automatically locked by the Lock bot SYSTEM: upload TYPE: bug
Projects
None yet
Development

No branches or pull requests

5 participants