python remote webdriver

1.how to config?The python script:

from selenium import webdriver
from selenium.webdriver.common.desired_capabilities import DesiredCapabilities
browser=webdriver.remote.webdriver.WebDriver\
                                               (command_executor='http://10.231.94.11:4444/wd/hub',browser_profile=profile,desired_capabilities=DesiredCapabilities.FIREFOX)


2.Then you should run the selenium server on the remote,like this:

java -jar selenium-server-standalone-2.x.x.jar

3.Then maybe you'll enconter a 'No displayed Error',on the server,excute this command "export DISPLAY=:0" before you run the selenium server.

你可能感兴趣的:(python,selenium)