Skip to content

Automation Testing Interview Questions in Visakhapatnam

36 practice questions with answers for Automation Testing interviews in Visakhapatnam.

Automation Testing jobs in Visakhapatnam

Visakhapatnam (Vizag) has a developing IT market with delivery centres, start-ups and IT parks around Rushikonda. Many local candidates also apply to Hyderabad and remote roles, so a mix of service and product styles is common.

Below are 36 questions that match the mix of service, product and domain employers hiring automation testers in Visakhapatnam.

Solved for VisakhapatnamStart practicing
3 QUESTIONS FREESign up to unlock the full question bank and track your progress.Unlock every question and answer, then continue practising company-wise and package-wise.
3 questions free Unlock the rest in seconds
01

Write a TestNG listener that logs test start and failure.

Save to ▾
Show answer
public class LogListener implements ITestListener { @Override public void onTestStart(ITestResult r) { System.out.println("START: " + r.getMethod().getMethodName()); } @Override public void onTestFailure(ITestResult r) { System.out.println("FAIL: " + r.getName() + " - " + r.getThrowable()); } } // register with @Listeners(LogListener.class) or <listeners> in testng.xml
02

What is an API and what are common HTTP methods?

Save to ▾
Show answer
An interface for systems to talk to each other. GET reads, POST creates, PUT replaces, PATCH updates partially and DELETE removes.
03

How do you run the same test with data from Excel using a DataProvider?

Save to ▾
Show answer
Write a utility that reads the sheet with Apache POI and returns Object[][] with one row per test case. Create a @DataProvider method that calls the utility, and set dataProvider = "loginData" on the test. Each row runs as a separate test with its own result. Keep the file in src/test/resources and consider CSV or JSON, which are easier to review in Git.
04

Write an XPath for a button with the text "Login".

Save to ▾
Show answer
//button[normalize-space()='Login'] //button[contains(text(),'Login')]
05

What is the use of the this and super keywords?

Save to ▾
Show answer
this refers to the current object; super refers to the parent class, used to call parent constructors and methods.
06

How do you manage test data in a framework?

Save to ▾
Show answer
Use external files or APIs and database setup scripts, generate unique data per run, and clean up afterwards so tests stay independent.
07

What is the difference between average, median and 95th percentile response time?

Save to ▾
Show answer
Average is the sum divided by count, so a few very slow requests can distort it. Median is the middle value, meaning half the requests were faster. The 95th percentile means 95 percent of requests were faster than that value, which reflects what most users experience including slow cases. SLAs are usually written on 90th, 95th or 99th percentiles because averages hide long tails that frustrate real users.
08

Your UI regression suite has 15 percent flaky failures. How would you bring it under control?

Save to ▾
Show answer
Measure flakiness per test over many runs and fix the worst first. Typical fixes are replacing sleeps with explicit waits, creating independent test data via API, avoiding shared logins, using stable locators, isolating parallel drivers and stubbing unstable third parties. Quarantine known flaky tests into a separate job so they do not block releases, and set a target like under 2 percent.
09

What are Java collections and which ones do testers use most?

Save to ▾
Show answer
ArrayList and LinkedList for lists, HashSet for unique values, HashMap for key-value test data, and Iterator for traversing them, for example collecting web elements in a list.
10

How do you switch between native and webview contexts in a hybrid app?

Save to ▾
Show answer
// Requires the webview to be debuggable in the app build Set<String> contexts = driver.getContextHandles(); for (String ctx : contexts) { if (ctx.startsWith("WEBVIEW")) { driver.context(ctx); break; } } driver.findElement(By.cssSelector("#email")).sendKeys("qa@test.com"); // back to native controls driver.context("NATIVE_APP");
11

What are Java 8 streams and lambdas?

Save to ▾
Show answer
Lambdas are short anonymous functions; streams process collections declaratively with filter, map and collect, for example filtering link text from a list of elements.
12

What is git cherry-pick?

Save to ▾
Show answer
git cherry-pick <commit> applies the changes of one specific commit onto your current branch, creating a new commit. It is useful when a fix on one branch, such as a locator fix on develop, is urgently needed on a release branch without merging everything else. Overuse creates duplicate commits and confusing history, so prefer normal merges when possible.
13

How do you build dynamic JSON request bodies without hard-coded strings?

Save to ▾
Show answer
Use POJOs with a builder pattern or Lombok @Builder, so tests write User.builder().name("Ravi").role("QA").build(). For quick cases use a HashMap or Jackson ObjectNode. For large templates, keep a JSON file and change fields with a JSON library. Combine with a faker library for unique values. This avoids escaping issues and makes changes to the schema easy to update.
14

How do you handle dynamic elements whose ids change?

Save to ▾
Show answer
Use CSS or XPath with contains(), starts-with() or stable attributes, relative axes, or data-test attributes agreed with developers.
15

What is ITestContext in TestNG and how can you use it to share data?

Save to ▾
Show answer
ITestContext represents one test tag from testng.xml and is passed to listeners and configuration methods. It holds the suite, included methods and results, and has setAttribute and getAttribute to share values, such as an auth token created in @BeforeTest and read by later classes. Because it is shared by every thread in that test tag, store only thread-safe or read-only data there, not WebDriver instances during parallel runs.
16

How do you create a custom parameter type in Cucumber?

Save to ▾
Show answer
Annotate a method with @ParameterType, giving a regex and returning a domain object. For example @ParameterType("admin|manager|viewer") public Role role(String name) { return Role.valueOf(name.toUpperCase()); } lets you write steps like "I log in as {role}". It keeps conversion logic in one place, makes steps type-safe and gives clearer errors when an invalid value is used.
17

What does dependsOnMethods do?

Save to ▾
Show answer
It makes a test run only after specified tests pass, otherwise it is skipped. Use sparingly as it creates coupled tests.
18

What is CI/CD and why does automation need it?

Save to ▾
Show answer
Continuous Integration builds and tests every commit, and Continuous Delivery ships automatically. Automated tests give fast feedback and gate releases.
19

What are the main components of Selenium Grid 4?

Save to ▾
Show answer
Grid 4 is split into the Router, which receives all requests, the Distributor, which assigns new sessions to nodes, the Session Map, which records which node owns each session, the New Session Queue, which holds requests waiting for a free slot, the Event Bus, which lets components communicate, and Nodes, which run the browsers. In standalone or hub mode these run in one process, but they can also be deployed separately to scale.
20

How do you mock an external API in automation tests?

Save to ▾
Show answer
Use a tool such as WireMock or MockServer to run a stub server that returns predefined responses for given requests. Point the application or tests to the stub with configuration. This lets you test error codes, timeouts and edge cases that are hard to trigger on the real service, and keeps tests stable when the third party is down. Still keep a few tests against the real integration.
21

Where do you use OOP concepts in your framework?

Save to ▾
Show answer
Encapsulation: private locators with public page methods. Inheritance: pages extend a BasePage. Polymorphism: the WebDriver interface for different browsers. Abstraction: utility layers hiding Selenium details.
22

During a load test response times rise sharply. Which server-side metrics do you check?

Save to ▾
Show answer
Check CPU and memory usage of application servers, garbage collection pauses and heap usage for Java services, thread pool and connection pool saturation, database slow queries, locks and connection counts, disk I/O and network bandwidth. Also look at load balancer and cache hit rates and error logs. Correlate the timestamp of the slowdown with these graphs in an APM or monitoring tool to find which resource saturated first.
23

What are the advantages of version control for test code?

Save to ▾
Show answer
Git tracks changes, enables code review, branching and rollback and lets teams collaborate on the framework safely.
24

What is a BasePage and what should it contain?

Save to ▾
Show answer
BasePage is a parent class for all page objects holding common things: the driver reference, a WebDriverWait, and helper methods such as click with wait, type, getText, waitForVisible and scrollIntoView. Child pages extend it and stay focused on page-specific locators and actions. Keep it small; if it grows into hundreds of methods, move helpers into separate utility classes using composition.
25

How have you handled disagreement with a developer about whether something is a bug?

Save to ▾
Show answer
Situation: a developer said a rounding difference in invoice totals was expected. Task: resolve it without friction. Action: I checked the requirement, found it specified rounding per line, and brought the document and a test case with expected values to a quick call with the BA. Result: the BA confirmed it was a bug, it was fixed, and we added the rule to the acceptance criteria.
26

What is Selenium Grid and why use it?

Save to ▾
Show answer
It runs tests in parallel across multiple machines and browsers using a hub and nodes, cutting execution time and increasing browser coverage.
27

What is the Transaction Controller in JMeter used for?

Save to ▾
Show answer
A Transaction Controller groups several samplers into one logical business transaction, such as Login, which may include loading the page, posting credentials and fetching the dashboard. JMeter reports an extra sample with the total time of the group, so reports show user-level timings instead of only individual requests. With generate parent sample enabled the children appear nested. It makes SLA reporting easier for business stakeholders.
28

What is the difference between static and non-static members?

Save to ▾
Show answer
Static members belong to the class and are shared by all instances; non-static members belong to each object.
29

How do you handle a website that uses CAPTCHA?

Save to ▾
Show answer
Do not automate it; ask for a test environment where CAPTCHA is disabled or use test keys, or a bypass token agreed with developers.
30

Tell me about a time you moved from web automation to mobile automation.

Save to ▾
Show answer
Situation: my team needed Android regression tests and I only knew Selenium. Task: deliver a smoke suite in one month. Action: I learned Appium 2 setup, used Appium Inspector to find locators, asked developers to add accessibility ids, and reused our TestNG, POM and reporting structure with a new driver factory. Result: twenty smoke tests ran nightly on emulators within four weeks, and release smoke testing dropped from half a day to forty minutes.
31

An API returns 200 but your REST Assured assertion on a field fails with a null value. How do you debug it?

Save to ▾
Show answer
Log the full response with then().log().all() to see the actual body. Common causes are a wrong JSON path, such as missing a wrapper like data, the field being in an array needing an index, a different content type like XML or HTML error page, or the field name having different case. Fix the path, and add a schema check so structure changes are caught clearly.
32

What is shift-left testing?

Save to ▾
Show answer
Shift-left means testing earlier in the development cycle: reviewing requirements, writing acceptance criteria and test cases before coding, running unit and API tests on every commit, and giving developers fast feedback. Defects found early are cheaper to fix. In practice SDETs pair with developers, add tests to pull request pipelines and test APIs before the UI is built.
33

Your Jenkins test stage marks the build green even though tests failed. Why?

Save to ▾
Show answer
Possibly testFailureIgnore is set to true in Surefire, the shell step uses || true, or the script swallows Maven's exit code. Sometimes tests catch exceptions and never fail. Check the console log for Maven's BUILD result and Surefire summary. Fix the configuration so failures produce a non-zero exit, or use junit publishing to mark the build unstable when tests fail.
34

What is the Optional class in Java and where is it useful in test code?

Save to ▾
Show answer
Optional is a container that may or may not hold a value, introduced in Java 8 to avoid returning null. In test code it suits lookups that can legitimately find nothing, such as finding a row in a table or reading an optional config key. Callers use orElse, orElseThrow or ifPresent instead of null checks. For example, findRowByName(name).orElseThrow(() -> new AssertionError(name + " not found")) gives a clear failure message.
35

How do you validate a response against a JSON schema in REST Assured?

Save to ▾
Show answer
Add the json-schema-validator dependency, place the schema file in src/test/resources, and assert with then().body(matchesJsonSchemaInClasspath("user-schema.json")). Schema validation checks field types, required fields and structure, so it catches contract changes that value checks might miss. It complements, not replaces, assertions on business values like status or totals.
36

How do you check that the Grid is ready before starting the tests in CI?

Save to ▾
Show answer
Poll the Grid status endpoint, http://hub:4444/status, until the JSON field value.ready is true, which means at least one node has registered. In a shell step you can loop with curl and jq, for example until curl -s http://localhost:4444/status | jq -e '.value.ready'; do sleep 2; done, with an overall timeout. In Compose you can add a healthcheck on the hub. Without this, the first tests fail while nodes are still starting.

Few big employers listed in Visakhapatnam?

Many Visakhapatnam candidates also apply to teams in Hyderabad and to remote or hybrid roles. Practise the Hyderabad set as well.

Frequently asked questions

Which companies hire Automation Testing professionals in Visakhapatnam?

Companies with large offices in Visakhapatnam include many IT services and product firms. Use their company pages below to practise employer-specific sets.

Are Automation Testing interviews in Visakhapatnam different from other cities?

The questions depend more on the company than the city. Visakhapatnam's mix of employers decides the style: Many local candidates also apply to Hyderabad and remote roles, so a mix of service and product styles is common

How do I find Automation Testing jobs in Visakhapatnam?

Shortlist companies with Visakhapatnam offices, keep your CV focused on Automation Testing projects, apply on company career pages and job portals with the Visakhapatnam filter, and practise the questions on this page before each interview.