Testbytes IN website

Automation Testing Tutorial For Beginners

April 30th, 2019
Automation Testing Tutorial For Beginners

Automation testing not only relieves testers of repeatedly executing the same test cases again and again but also enhances the execution speed and decreases the chances of human prone errors. Will not you like something as effective as automation testing to be on your stride?
Let us learn more about automation testing here
What is Automation Testing?
Automation Testing, automates the manual testing nullifying human efforts.  It uses an automation tool to run your test cases. These automation tools do not require any human intervention and automatically enters test data into the System under Test, compare expected and actual results and generate detailed test reports.
Why do I spend Extra Money on Automation testing?
Below mentioned benefits of automation testing will definitely convince you to consider automation testing for your system and will assure you it will not be a waste of money.

  1. Sometimes you have to repeatedly execute the same test cases for many numbers of times, test automation tool allows you to record the test suite and re-execute it when required.
  2. Thus it eliminates the boredom of executing the same test case again and again. It also improves the ROI as no human intervention is required for automated test suits.
  3. Automation testing saves time, as manually testing all scenarios for various devices and browsers can be very time-consuming.
  4. Testing multilingual sites manually can be very difficult; hence automation testing is very beneficial in such a case.
  5. In case of long test cases, they can be left unattended whole night in automated testing.
  6. Increases the speed of testing.
  7. It gives wider coverage of test cases.
  8. Manual testing can be boring at times and can hence be error-prone; this issue is very well taken care by automated testing.

But it is not a good idea to automate all type of testing, so be particular in deciding when to automate your test cases and when not.
Which Test Cases should We Automate?
Our main aim is to get a higher ROI. Based on it, here are few test cases you can consider automating

  • High Risk – Business Critical test cases
  • Test cases to be executed repeatedly
  • Tedious or difficult test cases
  • Time-consuming test cases

There are a few types of test cases that are better suited for manual testing. So it is better not to automate such test cases.

  • New test cases that are not even manually executed even once
  • Test Cases with frequently changing requirements
  • Test cases executed on an ad-hoc basis.


What are the Common Myths of Automation Testing?
Many myths are linked to software testing. It is important to be well aware of these misconceptions before you kick off your automation testing
Some of the common myths associated with automation testing are:

  • Automation completely replaces Manual Testing

Automation testing is definitely not a complete replacement of manual testing. There are many unpredicted scenarios that might require human intervention and there are some errors that are better determined by manual testing.

  • Automation Testing is not necessary, Manual Testing provides a solution to all kinds of Testing.

There is another side of the coin where some people believe that everything can be done manually. But there are some scenarios like regression testing where manual testing cannot be effective and might take longer to accomplish the tasks.

  • Automation consumes a Lot of Time

It might seem that automating the tests is time-consuming, but if we consider the complete picture, once automated, the automation testing can save us a lot of time.

  • Automation Is Very Easy

Automation testing as believed is not an easy-peasy task. Writing test scripts requires knowledge and experience and is definitely not an easy task. But if you compare it with manual testing, it definitely is easier if you know how to write the test cases.

  • Automation is only for Regression Testing

To much automation testing is only meant for regression testing. But the fact is that it covers many other areas like performance, product setup, security, compatibility, and many others.

  • Automation testing does not require cooperation between the Testers

It is completely a myth that automation testing has nothing to do with cooperation among the testers. Software development as a whole requires a fine-tuning among the engineers and automation testing is no different and requires close cooperation between the testers.

  • It returns a Faster ROI

Automation testing is a long term process and expecting immediate returns on your automation investments is a huge mistake. You have to be very patient to start getting a positive ROI.

  • Automation Testing only detects Bugs

If you are the one who believes automation testing only finds the errors then let us acknowledge you with its other benefits. It delivers valuable data and insights which help in improving the end product and solve many technical issues.
What should you do and what not in Automation testing?
There are always Dos and Don’ts for everything. These dos and don’ts are very important to perform your task effectively. Here are dos and don’ts of Automation testing that can help you conduct your automation testing effectively.
The Dos of Test Automation

  1. Break Your Tests Into smaller And Autonomous Scenarios

Shorter and more specific scenarios can help you detect issues with ease. Single test scenario makes troubleshooting difficult.

  1. Choose the Tests to Automate wisely

Automating all the test cases are not a wise idea, so be very ingenious while selecting the test cases to automate.

  1. Start small, don’t hurry

Don’t be in a hurry to create the complete test suits all at once. Follow the project’s workflow and automate only what is required.

  1. Set Priorities

Prioritize your work. Spend more time on test cases for the functions that are more crucial the simple and less important ones.

  1. Employ Professionals

Using an expert hand for your automation testing requirements can promise you greater benefits.
The Don’ts of Test Automation

  1. Do Not start Automating From the First Day Itself

Don’t be in a haste to automate your test cases. Give your project a little time and understand the scope of automation for your project.

  1. Don’t Try Running Everything at Every Time

It’s certainly not a good idea to test everything all the time. Spend time on testing only the functionalities that require testing and don’t waste time on testing everything all the time.

  1. Don’t Automate All the Manual Tests

Automating everything is not a good idea. Manual testing holds a very important place in software testing and is capable of finding the most unexpected defects at time.

  1. Don’t Automate Everything

Don’t just automate everything; it could be simply a waste of time and money.

  1. Don’t Ignore Further Development

Don’t ever think your work of automation testing is done. Keep a track of developments in the project and don’t miss to add test cases for them.
How to automate Test Cases?
Automating test cases follows a predefined process. Here are the basic steps to follow while automating your test cases.

  1. Test Tool selection

Test Tool we select is largely dependent on the technology your application is built on. It’s a good idea to conduct a Proof of Concept of Tool on Application Under Test.

  1. Define the scope of Automation

The scope is the part of your Application that has:

  • Scenarios with extensive data
  • Business important features
  • Functionalities that is common among applications.
  • Technical feasibility
  • Components with Reusable test cases
  • Complex test cases
  • Components to be tested across cross-browser testing
  1. Planning, Design, and Development

This phase is all about automation, strategy, design, and development. Your automation planning and design should include the below-given points:

  • Shortlisted Automation tools
  • Design and features of the Framework
  • Automation testbed preparation
  • Scripting and execution schedule and timelines
  • All the Deliverables

  1. Test Execution

Finally, it’s time to execute the test cases. In this phase, input test data are set to run and after execution, the test report is produced. You can directly execute test cases through automation tools or through test management tools that further invoke the automation tools.

  1. Maintenance

Maintenance is an on-going and a very important phase of automation testing life cycle. Whenever new functionalities are added to the system under test, automation scripts need to be reviewed and revised. Hence maintenance becomes important to enhance the effectiveness of automation scripts.
What are the various tactics for Automation Testing?
Automation testing is a crucial part of STLC. To accomplish it you can follow any of these three approaches.

  • Code-Driven: Code-driven automation testing, which is popularly used in agile software focuses on validating whether the code works as per expectations or not.
  • Graphical user interface (GUI) testing: It is meant for GUI rich applications. User actions can be recorded here and can be analysed multiple times. It supports test cases in multiple languages like C#, Java, Perl, Python, etc.
  • Test Automation Framework: A Set of automation guidelines, modularity, project hierarchies, concepts, coding standards, reporting mechanism, practices, processes, test data injections, etc. are predefined to help execute automation testing effectively.

These are the various methods that you can deploy to automate your software testing. Let us now learn in detail about the most important one – Framework for Automation
A Set of automation guidelines, modularity, project hierarchies, concepts, coding standards, reporting mechanism, practices, processes, test data injections, etc. are predefined to help execute automation testing effectively.  You can use these guidelines while automating test cases to get effective results.
What are the advantages of Test Automation Framework?

  1. Enhances code Reusability
  2. Maintains test consistency
  3. Gives Maximum coverage
  4. Minimum code usage
  5. Recovery scenario
  6. Low-cost code maintenance
  7. Minimal manual intervention
  8. Data involvement when required
  9. Reduced training period
  10. Easy Reporting
  11. Enhanced test structuring

There are five types of frameworks used in automation software testing:

  • Data-driven Framework: It focuses on separating test scripts logic from test data.
  • Linear Scripting Framework: Focuses on sequential or linear recording and replaying of test scripts.
  • Modular Testing Framework: Dividing application into numerous modules and creating their test scripts separately.
  • Hybrid Testing Framework: A combination of all the frameworks to pull the powers of each.
  • Keyword-driven Framework: test scripting is done based on the keywords specified in the excel sheet and accordingly tests are executed.

What are the Automation Testing Best Practices?
The below given best practices can help you increase your ROI and to get the best result from your automation testing:

  • It is always advisable to set the scope of Automation before starting the project. It helps in setting the right expectations from the project.
  • Selecting the right automation tool can make a huge difference in your testing results. You should always select the tool that suits your requirements and not the one with the best ratings and high popularity.
  • The framework plays a very important role in the success of automation testing. So spend time in creating a framework for your automation.
  • Always follow the best Scripting Standards. You can follow the below-given standards to meet your requirements.
  • Create uniform comments, scripts, and indentation of the code
  • Be prepared for Exception handling; the automation tool should be well prepared to handle unexpected errors and exceptions in.
  • For the ease of testers, the error logging messages should be standardized.
  • Defining the Success of automation requires some metrics. You cannot just compare the manual effort with the automation effort. Below are some of the metrics that you need to take into account to define your automation test success:
  • Defects percentage
  • Productivity improvement
  • Automation testing time for each cycle
  • Minimal release Time
  • Index for Customer Satisfaction

What are the Advantages of Automation Testing?
Automation testing has many advantages and it is a good idea to consider it for your testing whenever required.

  • It is around 70% quicker than manual testing
  • The results of automation testing are more reliable and less prone to human intervened errors
  • Automation testing Guarantee Consistency
  • It saves a lot of Time and Cost
  • Higher ROI
  • Increases accuracy
  • Does not require any Human Intervention for execution
  • It enhances Efficiency
  • Test scripts can be re-used whenever required, hence saving a lot of time for recreating them.
  • Automation testing gives a wider coverage of test cases

Know More: Top 10 Automation Testing Tools 2019

What are the Applications of Automation Testing?
Automation can cover a big part of testing. Some of the common applications of automation testing are:

  • Performance testing: Automated testing is very efficient for testing the performance of your software product.
  • Test data generation:  Automation testing can help you to program tests to automatically generate entry data.
  • Product Setup:  Automating Product setup ensures that your software product is efficiently set up.
  • User interface components’ interaction: It takes care of smooth interaction between various components of a user interface.
  • Regression Testing:  Automated regression testing helps to avoid errors incurred because of code changes.
  • Security Testing:  Atomization of tests helps in easy detection of security-related bugs if any.
  • Functional (White-Box and Black-Box):  Functional testing can be a daunting task at times; it is a wise idea to automate functional testing.
  • Installation / Integration / System: Testing installation/integrations and system bugs can be head honking if done manually. Automation of such test cases can easily ensure proper installation and integration of components within a system.
  • Smoke and Sanity Testing: Automated scripts can reliably conduct both smoke and sanity testing.
  • Usability/UI/GUI Testing: The user interface, GUI and usability testing are other tests that can be better if automated
  • Compatibility: Compatibility testing is another task which is very time consuming and daunting if done manually, automating compatibility testing can promise better results and wider coverage.
  • Internationalization: Internationalization is better when automated.
  • User Acceptance: User acceptation demands greater accuracy, and Automation promises you enhanced accuracy.

How to Choose Which Automation Testing Tool is best for me?
You cannot just randomly pick an automation tool for your automation testing. Picking up the right tool is very important for getting the maximum benefit out of your automation testing. The following criteria can help you pick the best automation tool:

  • Environment Support
  • Testing of Database
  • Ease of use
  • Image Testing
  • Object identification
  • Object Mapping
  • Tools that support various types of test
  • Error Recovery Testing
  • Scripting Language Used
  • A tool that can identify objects in every environment
  • Multiple testing frameworks support
  • Easy to debug the automation software scripts
  • Minimal training cost
  • Detailed test reports and results

What are the Various Automation Testing Tools?
Selecting the best automation tool is a challenging task. We would advise you to first identify your requirements, study about different automation tools and their features and then choose the one that fits your requirements the best.
Here are the Names of some very Popular Automation Testing Tools.

  • Selenium – It is a very popular automation testing tool for a web application, supporting various platforms and browsers.
  • Watir – It is an open source automation testing tool for web applications. It is created using Ruby libraries.
  • Ranorex – Ranorex is a GUI automated testing tool for multiple environments and devices.
  • Appium – Appium is known to be one of the best Open source mobile automation testing tool.

Can We trust all Testers for our Automation Testing needs?
With time automation testing has become very simple and a manual tester can easily accomplish it if he has a good business.
Any tester can execute expert’s created test automation scripts.
But there is another side of the coin, there are different skill sets that require more technical knowledge which is not easy to be learned by a manual tester overnight.
Today a test automation expert is expected to design an overall automation strategy for the entire product.
They require knowledge to select the right set of tools for every stage and give a cost-effective and unified integration strategy.
Automation testers are also expected to develop functions that can reduce manual testing and test data generation work.
Hope you would have found this article informative!

Testbytes IN website
Recent Posts
Subscribe
Please enter valid email address



Contact Us
Please enter valid email address
Phone
Please enter message


Testbytes IN website

Search Results for:

Loading...