Do you have an important automation testing interview? Are you also worried about the questions asked? Then do not fret. We have curated the top 25 frequently asked automation testing interview questions. These are quick 10 min read questions that will definitely help you and prep you to crack the interview.
Ques.1. What is automation?
Ans. Automation is a method of running repetitive tasks, with minimum or about zero human assistance. This process is adopted to reduce human efforts.
Ques.2. What is automation testing?
Ans. Automation testing is using automation tools to create and execute test cases. It helps in finding defects and test the overall working of the software. In automation testing, the test results are also generated automatically without the need for human intervention.
Ques.3. What is the need for automation testing?
Ans. Automation testing is important as-
- It reduces human work/effort.
- It saves from boring and tiresome monotonous work.
- No need to create new test cases each time software is to be tested.
- Fewer chances of error.
- Speeds up the process of testing.
- Reduces the cost of testing.
- Easier to maintain test cases of lengthy and large applications or projects.
- When manual testing becomes impossible.
Ques.4. How to decide if automation testing is required?
Ans. The automation testing is required if-
- For similar repetitive tasks.
- When large data is involved.
- Smoke and Sanity testing.
- Regression test suite.
Ques.5. Is complete 100% automation possible?
Ans. There are cases when the webpage might have a captcha. Or, there are test cases that are run seldom so automating such cases won’t bring any advantage. Therefore, having 100% automation is not possible.
Ques.6. During what circumstances automation is not feasible?
Ans. Automation testing is not feasible-
- During random testing.
- When the project is small and can be handled manually.
- When the application under test is dynamic i.e. changes frequently.
Ques.7. What are the steps involved in automation testing?
Ans. The steps involved are-
- Selection of appropriate test tool.
- Planning and design
- Test execution
Ques.8. What are the prerequisites before starting an automation project?
Ans. Some of the things to keep handy or have pre-requisite knowledge of are-
- The Software Requirement specification document.
- Choosing an appropriate tool for the testing phase.
- Selection of framework(if required).
- Deciding the type of test environment required.
- Listing the test deliverables.
- Preparation of a Gantt chart to keep the progress in check according to the timeline.
Ques.9. Are you aware of any common automation tools?
Ans. Yes. Some of the commonly used tools are Selenium, Jmeter, SilkTest, Load Runner, QTP, and Win Runner.
Ques.10. How does one decide which automation tool is appropriate for their project?
Ans. Things to be considered to select a tool for any project are-
- Should support the application and technology you are working on.
- Fits the cost and budget
- Availability of extra support like tutorials and videos.
- Easy to use
- Debugging facility
- Features to test the database
- Support for multiple frameworks
Ques.11. What is the difference between automation testing and manual testing?
Ans. In Manual testing, the test cases are written as well as executed by the tester itself. In Automation testing, specific automation tools are used to run the test scripts. This makes the testing process easier and faster.
Ques.12. What is a framework?
Ans. A framework is a set of rules or guidelines. These are followed to create a versatile, robust, and effective test suite (in case of automation).
Ques.13. What is the use of the framework?
Ans. Different files and tools are required during automation. A framework is a mix of practices and tools to ease automation. All of this is kept in an organized manner by the framework itself.
Ques.14. Is automation testing impossible without a framework?
Ans. We can do automation without a framework. But a good framework helps in creating a robust and standard way of writing scripts.
Ques.15. What are the different types of frameworks?
Ans. Different types of frameworks are-
- Hybrid testing framework
- Keyword-driven testing framework
- Data-driven testing framework
- Module-based testing framework
- Library architecture testing framework
Ques.16. What is a general structure of a framework?
Ans. A framework depends from project to project. However, a general structure would include-
- A source folder with test scripts
- A library folder consisting of libraries
- A class folder consisting of the class name
- Log folder having log files
- A file with URL, environment, and login information
Ques. 17. What attributes declare a framework a good framework?
Ans. A good framework will be-
- Reusable – Methods written in a common file must be accessible to all the test scripts.
- Independent – This means if one test case fails it should not affect the rest of the test cases.
- Continuous – The test suite should be continuous or consistent.
- Modular – The framework should be flexible enough to adapt to changes.
- Reporting – This feature of the framework will mail our results and reports once the scripting is complete.
Ques. 18. Why are URLs, logins and, passwords kept in a separate file and not in the code?
Ans. These are very frequently used information. Thus if embedded in the code, we will have to keep updating them for each file they are referred to.
Ques.19. What are the reasons one will refrain from automation testing?
Ans. Some of the common disadvantages of automation testing are-
- Might prove expensive. The cost of automation tools is quite high.
- Testing of UI or UX of the application is difficult.
- It takes a lot of time to write exhaustive test scripts.
- Requires a team of professionally trained and skilled engineers.
Ques. 20. What are some of the advantages of automation testing?
Ans. Some of the advantages of automation testing are-
- Increases the scope of test coverage.
- The requirement for resources is far less than in manual testing.
- It is more reliable.
- Execution of test cases way faster and more accurately.
- The team saves time for other levels in SDLC.
- More time to market the product.
- Reduction in maintenance cost.
- Improved product quality.
Ques.21. What will be your approach to testing a web application?
Ans. Whatever the application is it is important to choose the right automation tool. After this follow the following steps-
- UI testing of the website.
- The unique naming scheme for each web page.
- Grouping names for similar objects.
- Dynamic content should have an Xpath or ID.
- Cross-browser stability.
- Images should have the ALT attribute set.
Ques.22. What would be the automation strategy for agile software?
Ans. Some of the steps for effective automation will be
- Conduct parallel testing.
- Create quality test cases.
- Adopt DevOps integration.
- Choose the automation tool wisely.
- Cross-browser testing and cross-platform testing.
- Monitor the test environment regularly.
Ques.23. What will be your approach to automate a simple registration page?
Ans. To test the basic functionality of a registration page-
- Verify the requirements i.e. username field, password field, and a register button.
- Verify the UI of the page.
- Automating test case scenarios like-
- The fields should not be blank.
- Login should be possible with the registered email id and password.
- Do not accept invalid email id or passwords.
- Prepare data input according to the test scenarios.
- Run the test suite and report bugs, if any.
Ques. 24. What is a test script?
Ans. An automated test script is a short program written in any coding language to automate applications under test according to it. This program is then run. After that, the script itself marks the test cases as pass or fail based on the test logic.
Ques.25. What coding practices should one follow while automation?
Ans. Some of the good practices that one should follow while scripting are-
- There should be a proper indentation.
- At least 3 lines of comments for every 10 lines of code you write.
- The naming convention should be uniform.
- Maintain the test data systematically in different files.
- Run your codes regularly.
- The code should be robust enough to handle errors and recovery scenarios.
We have curated these questions independent of any specific coding language or automation tool. However, if you are to appear for an interview as an automation engineer, you should be well-prepared with at least one coding language. At the same time, have hands-on experience with any automation tool. This will help you gain more brownie points. Keep learning!
These automation testing interview questions are compiled by ArtOfTesting team member – Kanika Rawat. She is a tech enthusiast and loves coding.
Kuldeep is the founder and lead author of ArtOfTesting. He is skilled in test automation, performance testing, big data, and CI-CD. He brings his decade of experience to his current role where he is dedicated to educating the QA professionals. You can connect with him on LinkedIn.