50 Java Interview Questions for SDET Automation Engineer
Upasana | November 20, 2022 | 5 min read | 5,853 views
Basic Concepts
-
What is idempotent operation? What methods should be made idempotent?
-
How will you make REST automation framework? API automation
Java Questions
-
What is super class in Java?
-
What is Polymorphism? What is Abstraction, give a practical example.
-
How will you make sure that main thread is the last one to exit?
-
Main Interfaces in Collections API - List, Set, Map. What is the difference between them?
-
Enumerator vs Iterator? Which one is thread safe?
-
Can collection classes be made serializable. How to do that?
-
Catch NPE first and Exception in last, will that work? Discuss the exception hierarchy. What are the inheritance rules for Exceptions?
-
Error and exception difference with an example. StackoverflowError, OOMError, etc.
-
Which one is better - extending Thread class or implementing Runnable interface
Coding Problems
-
Calculate Fibonacci series in Java using recursion and iterative approach
-
Write a program to check if the given number is Armstrong number in Java
-
Searching an element from a sorted and rotated array.
-
Find two numbers of which the product is maximum in an array.
Algorithms and DS
-
How to find the relative efficiency of a given algorithms
-
Find first not-repeating character by iterating through the length of the string only once and by using constant space.
-
Print prime numbers up to x
-
Implement a stack data structure.
Testing Frameworks
-
JUNIT vs TestNG what are differences? Which one is better for QA?
-
TestNG hierarchy - Tests, suites, classes, etc.
-
Parameterization of tests in TestNG and data providers.
-
TestNG Listeners. How can these listeners be helpful.
-
Selenium and Rest API testing frameworks
-
How will you design API Testing suite
REST API Testing
Linux & Shell Scripting
-
How to run a process in the background
-
How to make sure that a program is restarted if terminated
-
How to list selected processes
-
How to kill a process
-
How to search for keywords in files in current directory
-
What is awk command, sed command
-
How to copy a file from one machine to another?
-
How will you enable password less SSH login into server machine?
-
Continuously monitor last 100 lines of a log file.
-
How to connect to a remote server and execute certain commands.
-
I want to read all input to the command from file1 direct all output to file2 and error to file 3, how can I achieve this? unix pipes.
-
Unix permissions concepts chmod +x file.
-
How does password less login works? At a higher level.
-
How to find size of current directory?
-
How to check free disc space and memory in Unix?
-
How to list all running processes and see their cpu utilization?
-
How to find a process running on given port in mac/ubuntu
-
How to search given directory for specific text
-
How to find a given process in Unix and kill it
-
How to start a process in background mode, so that it keeps running even after terminal is closed.
-
How to create a alias for a command in unix
-
How to setup public key authentication (passwordless login) on unix using ssh?
-
How to count lines and words in a text file.
-
How to get my IP address in unix
-
How a regular user can execute a command as an administrator
Database and SQL
-
Employee and Department table - all employees from employee table and only departments that exists for an employee from department table. Left outer join.
-
How to delete duplicate records from a given table. (duplicate based on specified fields)
Build Tools and CI/CD
-
Maven and Gradle basics (PMD rules, Firebug, Code coverage tools, etc.)
-
What is CI and CD
-
How is your CI/CD and build environment setup in your project. Jenkins, Regression Test, etc. explain the stuff.
-
How to setup a build pipeline in jenkins
-
How to seamlessly deploy to AWS ec2 cloud upon single commit in version control. Just the high-level steps/approach.
Security Testing
-
How will you test APIs from security aspects. What are different areas you will cover?
-
What is vulnerability, exploit and threat?
-
What are top vulnerabilities in a web application?
-
Which guidelines will you follow for security testing a web application?
Top articles in this category:
- Junit interview questions for SDET automation engineer
- Java Coding Problems for SDET Automation Engineer
- Rest Assured API Testing Interview Questions
- Essential Java Skills for SDET Automation Engineer
- How to reverse a number in Java
- Reverse a string using recursion in Java
- Java program for Fibonacci Series