Selenium WebDriver typing very slow in text field on IE browser

后端 未结 18 2407
感情败类
感情败类 2020-11-27 04:03

I\'m running one of my scripts on IE 11 browser with Selenium 2.43.1 when the script types in text field using following:

element.s         


        
相关标签:
18条回答
  • 2020-11-27 04:27

    My issue was with the driver architecture, and fixed it by downloading and using a 32bit one.

    To switch to 32 bit here is what you have to do

    1. Download 32 bit driver service from http://selenium-release.storage.googleapis.com/index.html
    2. Instantiate your InterExplorerWeDriver class using InternetExplorerDriverService class with path to 32 bit driver service.

      InternetExplorerDriver ieDiver = new InternetExplorerDriver(“Path to the 32 bit Explorer driver”);

    OR if using a builder:

    System.setProperty(“webdriver.ie.driver”,“C:\\drivers\\IEDriverServer.exe”);
    DesiredCapabilities ieCapabilities=DesiredCapabilities.internetExplorer();
    ieCapabilities.setCapability(InternetExplorerDriver
     .INTRODUCE_FLAKINESS_BY_IGNORING_SECURITY_DOMAINS,true);
    ieCapabilities.setCapability("requireWindowFocus", true);
    File ie_temp=newFile(“C:\\Selenium\\IEDrivertemp”);
    InternetExplorerDriverService.Builder 
    ies=newInternetExplorerDriverService.Builder();
    ies.withExtractPath(ie_temp);
    InternetExplorerDriverService service=ies.build();
    WebDriver driver=newInternetExplorerDriver(service,ieCapabilities))
    

    The thread that helped me resolve

    http://forumsqa.com/question/typing-too-slow-in-text-fields-while-replaying-tests/

    0 讨论(0)
  • 2020-11-27 04:27

    You can change to 32 bit version,it will be speed compare to 64 bit.

    0 讨论(0)
  • 2020-11-27 04:31

    I had the same problem when using the 64bit version of IEDriverServer. Change to the 32bit and It worked fine.

    Source: WebDriver and IE10 very slow input

    0 讨论(0)
  • 2020-11-27 04:32

    to improve the speed for send Keys function, one can perform below steps:-

    1. go to project-->properties->Java compiler-->under the java compliance --deselect the use compliance option and change the compile compliance level to 1.7 and then click to apply.

    It will work smoothly.

    0 讨论(0)
  • 2020-11-27 04:33

    For 64 bit WebDriver:

    1. Open IE
    2. Go to Internet Options → Advanced → Security
    3. Check ☑ Enable 64-bit processes for Enhanced Protected Mode
    4. Click Apply and OK

    For 32 bit WebDriver:

    1. Open IE
    2. Go to Internet Options → Advanced → Security
    3. Uncheck ☐ Enable 64-bit processes for Enhanced Protected Mode
    4. Click Apply and OK

    strangely:

    • The setting was necessary no matter if enhanced protected mode was activated or not.
    • Other than the text says in the dialog, restarting my computer was not necessary.

    My setup: Windows 10, IE 11, everything 64 bit, Selenium 3.4

    0 讨论(0)
  • 2020-11-27 04:33

    For IEServerDriver 3.14.0 this works for speeding up typing a bit.

    WebDriver browser;
    InternetExplorerOptions options = new InternetExplorerOptions();
        options.disableNativeEvents();
        options.requireWindowFocus();
    browser = new InternetExplorerDriver(options);
    

    DesiredCapabilities method is deprecated and options.IntroduceInstabilityByIgnoringProtectedModeSettings = true; and options.RequireWindowFocus = true; are no longer available.

    0 讨论(0)
提交回复
热议问题