ROBOTFRAMEWORK+SELENIUM2 environment Construction and Getting started example

Source: Internet
Author: User

First, the installation package

1, Python (recommended to use ActivePython, this version of path has been well-equipped, also a number of packages such as PIP)

Activepython-2.7.2.5-win32-x86.msi

2, WxPython (note to use 2.8 version, I use 2.9 of the discovery Ride cannot open)

Wxpython2.8-win32-unicode-2.8.12.1-py27.exe

3, Robotframework (I use 2.8)

Robotframework-2.8.1.tar.gz

4, install Ride (recommended with the following EXE installation package, it can create shortcuts on the desktop)

Robotframework-ride-1.1.win32.exe

1, https://pypi.python.org/pypi/decorator/

2, https://pypi.python.org/pypi/robotframework/#downloads

3, https://pypi.python.org/pypi/robotframework-selenium2library/1.5.0

4, https://pypi.python.org/pypi/selenium/2.40.0

You can choose to install online (requires networking) or install offline.

Second, on-line installation

1, first install Python, this will not have to say, the next step is good

2, installation Wxpython is also, the next step is good, note, it is best to run as an administrator

3. Install RF, run cmd as Administrator, pip install Robotframework

4, install ride, run cmd as Administrator, pip install Robotframework-ride

5, install selenium2library, run cmd as Administrator, then pip install Robotframework-selenium2library will be able to

To see if Selenium2library is installed successfully: Open python, enter import selenium2library, if a command prompt appears, note case, is selenium2library.

Third, offline installation

1, installation ActivePython

2, Installation Wxpython

3, install RF, decompression RF to a local directory (such as C drive), and then use the command line into the directory (CD \;CD robotframework-2.8.1) execute python setup.py install.

4, install decorator, the method and install RF, the first decompression and then enter the command line to execute Python setup.py install

5, install Selenium. Method Ibid.

6, install Selenium2library. Method Ibid.

7. Install Ride, run Ride installation package as Administrator.

Four, Try it

1. First Open ride

2. Create a new project:

The name and path can be set by itself, with a type and format on the right, and for the project, it is recommended to use Directory,format to select TXT, which is easy to manage

3. Create a new Suite

Here the type can choose file, the difference is that the file below can be directly written test case, and directory below can not

4. Create a new test case

5. Edit case

Before you edit a case, you need to import the Selenium2library library and add it to your suite.

Then enter the library name Selenium2library

Now we can edit the case.

Open Browse is a keyword, so it's blue. Keywords can be viewed by pressing F5

6. Perform the test

7. View the report

OK, very convenient, more detailed information please refer to Dr. Wu Gong's PDF file, this Baidu can be found a bit

ROBOTFRAMEWORK+SELENIUM2 environment Construction and Getting started example

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.