0
votes

I'm running Yii PHPUnit Selenium tests on a remote Windows VM using IE8.

Most of the tests work fine - but I'm totally stumped about how to handle uploads. I have the file I want to upload available on the remote VM. In all other browsers I'm able to use

$this->type('field', 'path/to/file');

But IE8 won't accept the typed input. I've attempted the steps manually, and the input won't allow me to type a path, I have to click the button to open the dialog.

I've also tried using $this->attachFile() (kinda the opposite of Selenium, PHPUnit, and AttachFile()) and that doesn't work either.

Does anyone have a good solution or workaround for this?

1

1 Answers

0
votes

To perform an upload I use (which works fine for me, don't know if it works on a Windows VM) :

    $this->byName('FileToUpload')->value('file');