0

I am using selenium and Chrome Driver to run codeception acceptance tests. However, my test script can't click an button on the website, it is shown this error message on my command prompt: [Facebook\WebDriver\Exception\ElementNotVisibleException] element not visible. The button is clearly visible on the browser and I tried the JQuery with:

$I->executeJS('jQuery("#edit-submit").show()');

edit-submit is the id for the button that I want to click. It still doesn't work.

  • 1
    Try to `I.waitForVisible('#edit-submit', timeout);` before manipulation with element. If the same error is still reproduced, then make sure that the necessary element is actually displayed by plugin `screenshotOnFail`. – fpsthirty Apr 06 '19 at 12:50

1 Answers1

0

You can use $I->scrollTo ("#edit-submit") command before $I->executeJS('jQuery("#edit-submit").show()')