Selenium2library using Remote function (reprinted and updated)

Source: Internet
Author: User

In the Open browser of the Selenium2library library, there are several less commonly used parameters in addition to the url,browser we commonly use. Such as: The use ofRemote_url

1. Download the Selenium-server-standalone-xxxx.jar Package

Https://code.google.com/p/selenium/downloads/list serarch selection: All Downloads

Select: Selenium-server-standalone-2.39.0.jar version.

2. Install the Java+python environment on the child nodes and configure the environment variables

3. Start the master node, that is, deploy the ride+framework+selenium2library environment

Enter commands at the command line Java-jar selenium-server-standalone-2.39.0.jar-role hub

Default boot default port is 4444, of course, you do not like 4444 can also change the port, plus-port xxxx can

When you're done, you can open http://localhost:4444/grid/console with your browser to see the status of the master node.

4. Start a child node

Now I have another machine as a child node (the master node can also be a child node). Same Open command

Java-jar selenium-server-standalone-xxxx.jar-role Node-hub Http://192.168.XX.XXX:4444/grid/register

Where 192.168.xx.xxx the IP address of the primary node, you can use the ipconfig command to view it at the command line. The above command starts port 5555 by default and can be changed using-port. Other parameter settings see for yourself, Https://code.google.com/p/selenium/wiki/Grid2.

You can then enter the Http://localhost:4444/grid/console URL on the master node to see the status of this child node.

5. After the deployment is complete, make the Test call in ride:

Open Browser URL gc remote_url=http://192.168.x.x:5555/wd/hub

OK, run it, no accident, the child node browser will be up!

6. Precautions:

The child node of the computer must also have a corresponding browser Driver,driver address must also be in path

Selenium2library using Remote function (reprinted and updated)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.