We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 27
Software Testing
Chapter 5 Test Automation and Tools Contents 1 What is Test Automation?
2 Why automated testing?
3 Advantage and disadvantage of automation testing?
4 When to use automation Testing
5 Automation Test Process
6 TDD and BDD approach
7 Common automation testing
1.What is Test Automation? ❖Test Automation/Automated testing uses the assistance of tools, scripts, and software to perform test cases by repeating pre-defined actions. ❖It completely depends on the pre-scripted test which runs automatically and compares the actual results with expected results 1.What is Test Automation? ❖Why automated testing? • No human intervention is required. • Testing multilingual sites • Increases speed of test execution • Increases test coverage • Manual testing becomes time consuming, costly and error prone What is Test Automation? 2. Advantage and disadvantage of automation testing? ❖Advantages: • save time and money: running tests 24/7, fewer Human resources • Automation does what manual testing cannot: Volume, Reusable • Improves reliability of the test • Reduces maintenance cost of testing • Increases amount of test coverage • Eliminates the need to do boring takes 2. Advantage and disadvantage of automation testing? ❖Disadvantages: • Test Automation requires lot of efforts at initial stage. • Programming Knowledge is required. • Debugging issues: use programming syntax/logic to write Tests, some times locating errors in Test Script is difficult. • Test Tools have Environment Limitations. • All types of Testing not possible (ex: usability) 3. When to use Manual and automatic testing 4. Automation Test Process 4.1 Test tool selection ❖The following parameters should be considered before selection of appropriate tool to be used for Test Automation: • Data driven/Test driven/Behavior driven capabilities • Hybrid framework • Debugging and logging capabilities • Platform independence • Extensibility and Customizability • …. 4.2 Scope of Automation ❖Scope of automation defines the area covered under automation for a software/application ❖Following points help to determine this scope: • Features which are crucial for the business • Scenarios/workflows covering tests which have a large amount of data • Common functionalities across applications • Technical feasibility • Reuse business components • Complexity of test cases 4.3 Planning, Design and Development ❖During this phase one creates an automation strategy and plan, which contains the following details: • Selecting appropriate automation tools • Creating the framework design and its features • Identifying In-scope, and Out-of-scope items of automation • Automation test bed preparation • Timeline for test case automation • Scheduling execution of automation suites • Deliverables of Automation testing 4.4 Test Execution ❖Automation scripts are executed during this phase ❖Test suite automation run could be directly executed from the automation tool or indirectly from a Test Management tool which will redirect the invoke request to the automation tool ❖Automation tool could execute the automation suites either on a single machine or distribute the suites on several machines to achieve faster results. 4.5 Maintenance ❖Since new functionalities are added with successive cycles, Automation scripts require update and also need to be reviewed and maintained for each release cycle. ❖Maintenance is necessary to make sure that the Automation scripts are in a stable state. 5. Test Driven Development (TDD) approach ❖It is an evolutionary approach to development which combines test-first development where you write a test before you write just enough production code to fulfill that test and refactoring 5. Test Driven Development (TDD) approach ❖RED – The developer writes a failing test essentially capturing the requirements in a test ❖GREEN – The developer implements the business functionality, writing just enough code to pass the test ❖REFACTOR – The developer refines and improves the code without adding new functionality. =>Demo. 5. Behavior Driven Development (BDD) approach ❖BDD is a technique in which developers, testers, business representatives work together to analyze the requirements of a software system, formulate them using shared language (Gherkin) and verify them automatically. 5. Behavior Driven Development (BDD) approach ❖TDD relies on unit tests to verify implementation details whereas BDD relies on executable scenarios to verify behaviors and more. ❖BDD follows a prescribed path: • Create user stories collaboratively • Formulate user stories as executable scenarios and verifiable behavior • Implement behaviors and execute the scenarios to verify them 5. Behavior Driven Development (BDD) approach ❖BDD scenarios are typically composed of three main sections: • Given – describes the state of the environment (preconditions) before the behavior is triggered • When- describes the actions that trigger the behavior • Then – describes the expected results of the behavior =>Demo 6. Common Automation Test tool ❖Selenium: • a testing tool for automating web application testing 6. Common Automation Test tool ❖Appium: • is one of the open-source automated testing tools primarily intended for mobile applications. • It backs automation of native, hybrid, and mobile web applications built for iOS and Android. 6. Common Automation Test tool ❖Cucumber • is an open-source Behavior Driven Development (BDD) tool • supports only the web environment 6. Common Automation Test tool ❖Katalon Studio • is an open-source and commercial test automation solutions. • Automate Web (UI and API) and mobile applications. • It can be integrated with a variety of other tools such as JIRA, qTest, Kobiton, Git, Slack, and more. 6. Common Automation Test tool
❖Unified Functional Testing (UFT)
• is known as QuickTest Professional (QTP) • Automate Web (UI and API), Desktop, mobile applications. • Only for Windows 6. Common Automation Test tool
❖HPE Unified Functional Testing (UFT)
• is known as QuickTest Professional (QTP) • Automate Web (UI and API), Desktop, mobile applications. • Only for Windows 7. How to Choose an Automation Tools? ❖Environment support ❖Ease of use ❖Object identification ❖Scripting language used ❖Support for various types of test – including functional, test management, mobile,.. ❖Error recovery testing ❖Multiple framework support ❖Minimize cost ❖Extensive test reports and cost.