Showing posts with label Watir. Show all posts
Showing posts with label Watir. Show all posts

Road to automation using watir for beginner

Watir installation:
1. Download and install the latest Ruby version from link “Ruby”. Setup ruby bin folder path to system environment variables. After installation and setup path run command:
ruby -v

2. setup OK if you get ruby version as a message.
gem  -v

3. You should update gem by using command.
gem  update --system

4. Watir and watir-webdriver gems need to “ffi” gem, and it needs Ruby Installer Development Kit (DevKit). Download DevKit  from link DevKit. and follow installation process as mentioned in url 
5. After DevKit successful installation, you need to install water and watir-webdriver by running following commands.
gem install watir
gem install watir-webdriver

6. After successfully installation of watir and watir-webdriver run some below commands to verify installation.

            Below message should be displayed
            DL is deprecated, please use Fiddle
>require "watir-webdriver"
            Message “true” should be displayed           
>browser = :ff
               Firefox browser should be open

Watir Ruby Based Automation Tool

About Watir:
Watir is an open source,  ruby based automation tool for web application. Watir drives application on web similar type as user do. It click on browser, fill form data, press button etc. Also it check result such as when any text appear on page.
Using ruby programming language we can make connection to data base, read files(csv, xls, txt, xml etc.) We can create our own function and library for reusable code.