Saturday, June 4, 2011

Selenium - Keyword Driven Framework

Selenium - Keyword Driven Framework.

Webdriver - Keyword driven framework using page objects

Having experience in implementing Hybrid framework in QTP, Initially I started converting this existing QTP framework into Selenium framework. Following are my challenges

1. Most of the user test data is stored in the MS excel files, there are open source APIs that can connect to excel files, but I had lot of issues reading and writing data continuously.
2. Test case PASS/FAIL status and summary report creation had custom logic as per the requirement.

As I didn't have enough time to over come above challenges currently, I have taken alternative approach.

I have extended the Selenium interface and written all user methods in that, so that I can create a clean test class. TestNG framework is taking care of test execution summary.

Note: Need to extend all the existing methods before adding new methods.
My intention is to hide the object locater information and user Keyword appear in the auto suggest list(Auto complete) in IDE environment.

Attaching the test class screen shot, where locator information is hidden in the interface methods.

Attaching Eclipse IDE screen shot where user methods are displayed in auto suggest drop down.



Attaching User method screen shot.



--

1 comment:

  1. Hi Bharath,

    It is really gud to have Keyword driven in selenium.

    Can you please explain how to extend selenium interface.

    If possible share that info to me @ cpwrama@gmail.com

    Thanks,
    Rama

    ReplyDelete