getting driver as null
attaching TestBase.java
what is happening is on line 174 of testbase your program is giving an exception null pointer. basically means is that you have no driver.findelement is not working reasons probably because it can't read the file or because it can't find the element and hence no size could be given or some other reason but first check these 2 first.
basically what happening that both classes in different packages and when i create object of TestBase and calling its function then driver not initializing. so i want to know what i do. when i debug driver getting null.
You have declared driver object locally You need to declare it globally
i have declared globally in TestBase like this. public WebDriver driver;
calling its function then driver not initializing. you have to watch the entire framework module 20 but the main point is driver has to be initialized in testbase with "Public static Webdriver=null;" and in a function you can start Firefox, Chrome, IE etc. and then you would have to make different functions for opening a website, basically anything.
We offer online selenium and UFT/QTP training. The course is very comprehensive and covers every aspect of automation testing with UFT/QTP and selenium. All types of frameworks are covered in depth - data driven framework, hybrid framework, page object model with a live project
© 2020 Whizdom Trainings. All rights Reserved - Powered by Whizdom Trainings