Automation Testing Interview For Experienced| Mphasis Interview Questions

preview_player
Показать описание
Throw Vs. throws

Explain the priorities of the Locators you applied in your project. How do you decide?

What does New do While object creation?
The Java new keyword is used to create an instance of the class. In other words, it instantiates a class by allocating memory for a new object and returning a reference to that memory.

Given string test234, extract the only number, write a logic?

How do you handle an element not visible exception?
First Solution: Try to write unique XPATH that matches with a single element only. Second Solution: Use Explicit wait feature of Selenium and wait till the element is not visible. Once it is visible then you can perform your operations

Why is PageFactory used?
The PageFactory can be used to initialize elements of a Page class without having to use FindElement or FindElements. When you are using the webelement(s) more then once your code gets better readable.

How to switch over the elements in iframes using Web Driver commands:
Basically, we can switch over the elements and handle frames in Selenium using 3 ways.

By Index
By Name or Id
By Web Element

How to handle nested iframes in Selenium WebDriver?
Print the number of frames with Selenium WebDriver inside this web page. ...
Switch to the parent frame using the id of the frame.
Print the number of frames using Selenium WebDriver inside the parent frame.

How do I switch my child to a parent window?
In order to switch its focus from the parent to the child window, we shall take the help of the switchTo(). window method and pass the window handle id of the child window as an argument to the method. Then to move from the child window to the parent window, we shall take the help of the switchTo().

How to close child browser window in Selenium WebDriver using Java?

Clear browser Cookies with Selenium WebDriver Java bindings.
We can clear browser cookies in Selenium. The method deleteCookieNamed shall delete a cookie with a specific name. The cookie named is passed as an argument to the method. First, we will add a cookie, then get it and finally delete it.

Syntax
Another method called the deleteAllCookies deletes all cookies from the existing domain. First, we will add the cookies, then get and delete them.

Syntax

what is build tool Maven
Maven is a build automation tool used primarily for Java projects. Maven can also be used to build and manage projects written in C#, Ruby, Scala, and other languages. The Maven project is hosted by the Apache Software Foundation, where it was formerly part of the Jakarta Project.

There are @Test1 and @Test2 methods in TestNG, but there are methods in Test1 which get executed only if Test2 gets executed. So how to approach?
How to rerun failed TestCases?
Explain how do you approach the Testing process if you are on day 1 of the sprint?
Explain which priority Test Suites you run in Automation,i.e., do you run all P1, P2, P3 suites in all the sprints every day?
Explain the priorities of the Locators you applied in your project. How do you decide?
Explain Regression Testing w.r.t Manual and Automation testing, what is the Approach?
Рекомендации по теме
Комментарии
Автор

The most humble and most patient interviewer i would say i have seen. And the best part is you give the answers and solutions right away which makes the video more interacting and useful.

Payalvloggs
Автор

I have seen many of your video and those are helpful.
You make candidate more comfortable and easy to answer or express knowledge.

sushil_
Автор

The Feedback or comments which you gave to Ankitha is a really good booster to me as well ("Support yourself")👍

poojajarugu
Автор

You are really a great man Rakesh !!
Doing a great job to improving your community skills
Thanks 🙏🙇

sahilsharma-jzpj
Автор

Sir Your videos are helping people a lot who want to make their career in software testing field,

bhupendraparihar
Автор

Regarding 'new' keyword. It basically calls the constructor of that class and then it's constructor's job to create the instance and allocate memory to that object

ramneekvlogs
Автор

I think we can use parameters.
Such as depends on and also we can give priority for that test case 2 as 0 and test case 1 as as 1 ==> so that we can achieve test 2 execute first and then test 1 execute

harshadkhairnar
Автор

There are two scenarios
If there are only two methods,
a. we can use the dependsOn parameters
b. also set priorities for the test cases

shyamvittal
Автор

Test 1 (priority =2)
Test 2 (priority =1)

sunilkhanadale
Автор

Thank you so much its really useful i literally enjoyed all your mock interview video most humble and most patient interviewer, i wish your channel would grow and reach new milestone in the days to come ❤❤❤❤❤❤

puspanjalikhora
Автор

We use for dependsOnMethods because testNG support dependency of one test method over other method,

Public void Test1(){
System.out.println("Home page test");
}
@Test
Public void Test2(){
System.out.println("login test")
}

madhurijadhav
Автор

we set the priority keyword means we set the first test case as a priority 1 and then second test case we set the priority 2

pratikkakad
Автор

Suggestions you gave are really Thank u

bumore
Автор

You are great sir, learned a lot from you

Netapaul
Автор

We can handle three ways
2. @BeforeMethod annotations in Test2
3. in Test2

advice
Автор

For the card payment scenario, two of the most important scenarios would be Payment Success and Payment Failure.

shyamvittal
Автор

class stringNum {
public static void main(String[] args)
{
String str = "test234";
char ch[] = str.toCharArray();
String dig = "";
for(int i=0; i<str.length(); i++)
{
if(Character.isDigit(ch[i]))
{
dig +=ch[i];
}
}
System.out.println(dig);
}
}


If not using string methods.

pujaguchait
Автор

Using priority keyword
Test 1 (priority =2)
Test 2 (priority =1)

shriramlandage
Автор

in test case 1,
use dependsOnMethds=method name(of test case2)

it means when test case2 execute then test case 1 will also execute.

ALLROUNDER_-bhvc
Автор

I will give the priority's to test cases

adurilavanya