Last modified: 2014-09-28 20:25:49 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T73397, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 71397 - Test multiple files into same input
Test multiple files into same input
Status: NEW
Product: MediaWiki extensions
Classification: Unclassified
UploadWizard (Other open bugs)
unspecified
All All
: Unprioritized enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-09-28 20:25 UTC by Neil Kandalgaonkar
Modified: 2014-09-28 20:25 UTC (History)
7 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Neil Kandalgaonkar 2014-09-28 20:25:49 UTC
Summary: At the moment, it's impossible to write an automated test for multiple files into the same input. Neither Selenium nor Watir support this. However, this is a heavily used feature. So, this bug just a TODO for figuring it out some day, and some notes on why we can't now.

Background:

If you click on an "add file" button, UploadWizard can accept a single file, or multiple files. Very old browsers only accept single files.

The script will add one Upload, with a related UploadWizardUploadInterface object for every file. So a single file input might actually be related to multiple UWUIs on the screen, with an index.

How to test this?

For security reasons, browsers don't allow scripts to set the contents of file fields.

Our testing frameworks[1] have a workaround: it's possible to send keystrokes (sendKeys) to a form input element. While there is no human UI for this, most web browsers will accept keystroke events that "type out" the full path.

However, it seems there is no convention for sending multiple file paths to an input this way. The Selenium people have a bug for this issue[2].


[1] right now, Cucumber -> PageObject -> Watir -> Webdriver -> Selenium -> an actual web browser.

[2] https://code.google.com/p/selenium/issues/detail?id=2239

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links