Sdet Automation Test Engineer

10+ Sdet Automation Test Engineer Interview Questions and Answers for Freshers

Updated 12 Jul 2025
search-icon
5d ago

Q. Wait in selenium and how to find all links present in a page xpath

Ans.

To wait in Selenium, we can use explicit and implicit waits. To find all links in a page using XPath, we can use the findElements() method.

  • To wait in Selenium, we can use explicit wait with ExpectedConditions or implicit wait with the setScriptTimeout() method.

  • Explicit wait waits for a certain condition to occur before proceeding with the next steps.

  • Implicit wait sets a maximum time for the driver to wait for an element to appear.

  • To find all links in a page using XPath, we ca...read more

3d ago

Q. What is page object model and test ng annotations

Ans.

Page Object Model (POM) is a design pattern used in test automation to create an object repository for web UI elements.

  • POM helps in creating reusable and maintainable code by separating the test logic from the page-specific details.

  • Each web page is represented as a separate class, and the UI elements and their actions are defined as methods within that class.

  • POM improves code readability, reduces code duplication, and enhances test maintenance.

  • TestNG annotations are used in T...read more

6d ago

Q. How do you handle alerts in Selenium, and what methods do you use?

Ans.

To handle alerts in Selenium, we use the Alert interface and its methods.

  • To switch to an alert, we use the switchTo() method of WebDriver class.

  • To accept or dismiss an alert, we use the accept() or dismiss() method of Alert interface.

  • To get the text of an alert, we use the getText() method of Alert interface.

  • To send text to an alert, we use the sendKeys() method of Alert interface.

5d ago

Q. How to take screenshot and project framework

Ans.

To take a screenshot in automation testing, use the built-in methods provided by the testing framework.

  • In Selenium, use the getScreenshotAs() method to capture a screenshot.

  • In Appium, use the getScreenshotAs() method to capture a screenshot.

  • In TestNG, use the ITestResult interface to capture a screenshot on test failure.

  • In Cucumber, use the After hook to capture a screenshot after each scenario.

Are these interview questions helpful?

Asked in Xyz Company

6d ago

Q. What is the software testing life cycle?

Ans.

Software Testing Life Cycle (STLC) is a process followed to ensure quality in software development by conducting various testing activities.

  • STLC consists of several phases: requirement analysis, test planning, test case development, test environment setup, test execution, and test closure.

  • Each phase has specific objectives and deliverables, ensuring that the testing process is systematic and thorough.

  • STLC helps in identifying defects early, reducing the cost of fixing them, a...read more

6d ago

Q. How many locators are present in Selenium?

Ans.

There are 8 locators present in Selenium.

  • Selenium provides 8 different locators to identify elements on a web page.

  • The locators are: ID, Name, Class Name, Tag Name, Link Text, Partial Link Text, CSS Selector, and XPath.

  • Each locator has its own syntax and usage.

  • For example, to locate an element by ID, you can use driver.findElement(By.id("elementId"));

Sdet Automation Test Engineer Jobs

Broadridge logo
Sdet Automation Test Engineer 1-3 years
Broadridge
3.9
Bangalore / Bengaluru
Capco Technologies Pvt Ltd logo
SDET Automation Test Engineer 4-7 years
Capco Technologies Pvt Ltd
3.7
Bangalore / Bengaluru
Wissen Infotech logo
Sdet Automation Test Engineer 5-10 years
Wissen Infotech
3.7
₹ 18 L/yr - ₹ 33 L/yr
Bangalore / Bengaluru
6d ago

Q. How do you find broken links?

Ans.

To find broken links, use a link checker tool or browser extension.

  • Use a link checker tool like Xenu's Link Sleuth or W3C Link Checker

  • Install a browser extension like Check My Links for Chrome or Link Checker for Firefox

  • Manually check links by clicking on them and checking for error messages

  • Regularly check for broken links to ensure website functionality

2d ago

Q. How are dynamic elements handled in Selenium?

Ans.

Dynamic elements in Selenium are handled using techniques like explicit waits, fluent waits, and dynamic locators.

  • Use explicit waits to wait for a specific condition to be met before interacting with the element

  • Use fluent waits to wait for an element to be present and visible before interacting with it

  • Use dynamic locators like XPath with functions to locate elements that change dynamically

Share interview questions and help millions of jobseekers 🌟

man-with-laptop

Asked in Vantiva

6d ago

Q. What is the difference between PUT and POST?

Ans.

PUT is used to update or replace an existing resource, while POST is used to create a new resource.

  • PUT is idempotent, meaning multiple identical requests will have the same effect as a single request

  • POST is not idempotent, meaning multiple identical requests may have different effects

  • PUT requires the client to specify the URI of the resource to update, while POST does not

  • PUT is typically used for updating existing resources, while POST is used for creating new resources

Q. What are the differences between smoke and sanity testing?

Ans.

Smoke testing is a quick test to check if the build is stable, while sanity testing is a more thorough test to check if the specific functionalities are working as expected.

  • Smoke testing is done to ensure the stability of the build before further testing, while sanity testing is done to ensure the specific functionalities are working correctly.

  • Smoke testing is a subset of regression testing, while sanity testing is a subset of acceptance testing.

  • Smoke testing is usually done ...read more

4d ago

Q. How do you implement the POM pattern in Java?

Ans.

POM (Page Object Model) is a design pattern used in test automation to create reusable and maintainable code by separating page objects from test scripts.

  • Create a separate class for each web page or component

  • Encapsulate the web elements and their actions within the page class

  • Use methods in the page class to interact with the web elements

  • In test scripts, instantiate the page class and call its methods to perform actions on the page

Q. How do you open a specific page and inspect a link element?

Ans.

Inspecting elements on a webpage helps identify links and their attributes for automation testing.

  • Use browser developer tools (F12) to open the inspector.

  • Navigate to the 'Elements' tab to view the HTML structure.

  • Right-click on the link element to view its properties.

  • Check attributes like 'href', 'target', and 'class' for automation scripts.

  • Use the 'Console' tab to test JavaScript commands related to the link.

Asked in Samsung

6d ago

Q. What status codes are used for API testing?

Ans.

API status codes indicate the result of an API request, helping to identify success or failure of operations.

  • 200 OK: The request was successful, and the server returned the requested data.

  • 201 Created: The request was successful, and a new resource was created.

  • 400 Bad Request: The server could not understand the request due to invalid syntax.

  • 401 Unauthorized: Authentication is required, and the request has not been applied.

  • 404 Not Found: The server can't find the requested res...read more

Q. Given an array of integers, find the duplicate number. There is only one duplicate number in the array, but it could be repeated multiple times. Each number in the array is between 1 and n (inclusive), where n...

read more
Ans.

Program to find duplicates in an array.

  • Iterate through the array and compare each element with the rest of the elements.

  • If a match is found, add it to a separate array or print it.

  • Use a hash table to keep track of the frequency of each element.

  • Sort the array and compare adjacent elements to find duplicates.

Q. Selenium waits , difference

Ans.

Selenium waits are used to pause the execution of the script, while the difference is in the way they wait for an element.

  • Implicit wait is used to wait for a certain amount of time before throwing an exception if the element is not found.

  • Explicit wait is used to wait for a certain condition to occur before proceeding with the execution.

  • Fluent wait is used to wait for an element with a certain frequency and timeout period.

  • The difference between them is that implicit wait is ap...read more

Interview Experiences of Popular Companies

TCS Logo
3.6
 • 11.1k Interviews
Infosys Logo
3.6
 • 7.9k Interviews
Wipro Logo
3.7
 • 6.1k Interviews
Amazon Logo
4.0
 • 5.4k Interviews
Capgemini Logo
3.7
 • 5.1k Interviews
View all
interview tips and stories logo
Interview Tips & Stories
Ace your next interview with expert advice and inspiring stories
Sdet Automation Test Engineer Interview Questions
Share an Interview
Stay ahead in your career. Get AmbitionBox app
play-icon
play-icon
qr-code
Trusted by over 1.5 Crore job seekers to find their right fit company
80 L+

Reviews

10L+

Interviews

4 Cr+

Salaries

1.5 Cr+

Users

Contribute to help millions

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2025 Info Edge (India) Ltd.

Follow Us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter
Profile Image
Hello, Guest
AmbitionBox Employee Choice Awards 2025
Winners announced!
awards-icon
Contribute to help millions!
Write a review
Write a review
Share interview
Share interview
Contribute salary
Contribute salary
Add office photos
Add office photos
Add office benefits
Add office benefits