Not able to handle multiple classes


Hi Lakshay,

This is what I am talking about.


These are two classes AgendiaLogin and second is worklist. Now what I am doing is I have main method in AgendiaLogin class only, suppose I want to write some code in worklist but want to call it from AgendiaLogin which has the main method. Then how should I do it.

I am making worklist class since I don’t want all my code to reside in single class which has main method.


Train Asked on August 14, 2014 in Selenium WebDriver.
Add Comment
  • 1 Answer(s)
    Best answer

    There are two ways of doing it. but the easy way of doing it is:




    Now in you AgendiaLogin class simply call the above Execute method of class Worklist like :



    You need to pass the driver, if in case you are not using base class.

    Still i suggest you to see Modular Driven Framework on my site

    Lakshay SHarma

    Train Answered on August 14, 2014.
    Add Comment
  • Your Answer

    By posting your answer, you agree to the privacy policy and terms of service.