23,99 €
Testing has traditionally been a part of software development, and has always involved a lot of manual effort. It can be automated with Robot Framework, which offers numerous benefits from cost saving to increased quality assurance in the software delivery. This book will help you to start designing test suites and Automated Acceptance Tests.
Helping you to get started with automating acceptance tests, this book will provide a detailed overview of acceptance test management practices and principles. You will also be introduced to advanced techniques that you can use to customize the test suite, along with helpful tips and tricks to extend and leverage it in a wide variety of scenarios.
Starting with a detailed explanation of the need for automated acceptance test driven development, this guide will help you with an empty test project creation and execution for proof of concept, and validation of installation. This book will also cover the Robot Framework in detail, and will help you test desktop applications using Java Swing. You will gain an in-depth knowledge of tricky activities, such as setting up a test environment and using it with Selenium.
You will also learn about other popular libraries, and how to test network protocols, web services, and databases. This book will cover the entire Robot Framework with real- world practical material to make its content informative and interesting.
By the end of this book you will be able to write acceptance tests for desktop and web applications, as well as know how to extend acceptance testing in other scenarios that are commonly devoid of tests, and present the results appropriately.
Das E-Book können Sie in Legimi-Apps oder einer beliebigen App lesen, die das folgende Format unterstützen:
Seitenzahl: 111
Veröffentlichungsjahr: 2013
Copyright © 2013 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
First published: October 2013
Production Reference: 1181013
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham B3 2PB, UK.
ISBN 978-1-78328-303-3
www.packtpub.com
Cover Image by Vivek Sinha (<[email protected]>)
Author
Sumit Bisht
Reviewers
Syed Mohd Mohsin Akhtar
Ismo Aro
Acquisition Editor
Pramila Balan
Commissioning Editor
Mohammed Fahad
Technical Editors
Dipika Gaonkar
Mrunmayee Patil
Sonali Vernekar
Project Coordinator
Michelle Quadros
Proofreader
Stephen Copestake
Indexer
Rekha Nair
Graphics
Abhinash Sahu
Production Coordinator
Melwyn D'sa
Cover Work
Melwyn D'sa
Sumit Bisht currently works as a Senior Software Engineer at a software service outsourcing firm. He has experience in both project and product-based companies and has done Masters in Computer Applications in addition to self-taught learning as part of his learning process towards making computers work. He has keen interests in leveraging various open source technologies for developing better software, considers himself a polyglot programmer and has experience working with different programming. While not working, he devotes his time in learning new researches and technologies, reviewing technical books on a wide variety of topics, sharing interesting information, and evangelizing open source philosophy through his blog, sumitbisht.blogspot.in.
I'd like to thank Vikram Mohan Sujanani for introducing me to the Robot Framework, while being my patient mentor, and Jayanti Kumar Srivastava for his support and expertise while unraveling elements of the framework. The entire Packt Publication team has worked tirelessly and persistently towards making this book a reality, and deserve a pat on the back. I am also grateful to Syed Mohd Mohsin Akhtar for reviewing this book. Last but not least, a huge thanks to Pekka Klärck and other members of the open source community for making available this versatile software and painstakingly extending help to various users.
Syed Mohd Mohsin Akhtar is a Software Engineer (R&D) at Encardio-Rite Electronics Pvt. Ltd., Lucknow, India. He received his M.C.A.(Hons.) from GBTU, India and eventually earned his spot as Software Engineer at DataBorough India a research subsidiary of DataBorough UK. He also has a specialized degree in Computer Maintenance from Aligarh Muslim University, India. He has been a Microsoft Student Partner, member OSUM (Open Source University Meetup), and an active member within several technical forums in his college days. He loves to work as a hobbyist in the areas of Computer Science and electronics. He can be contacted at <[email protected]>.
First of all, I am grateful to Almighty "Allah" for giving me strength.
I would like to express my sincere gratitude to Packt Publishing, for giving me the opportunity to have a first look at the book, and Sumit Bisht the author of this book for recommending me to review his book.
At last I would like to thank my parents, family, and my friends.
Ismo has a long history of working in agile projects as a change agent. He has a strong focus in modernizing ways of working and quality of work. Quality assurance is close to his heart and he has worked as a Product Owner of the Robot Framework, leading the development of it, and implemented good testing practices company-wide.
At the moment he is working for Basware Corporation as a Lead QA Engineer, responsible for bringing in world-class Agile Testing and Test Automation. His previous employers have been Nokia Networks, Nokia Siemens Networks, and Ericsson.
I want to thank my lovely wife and my two amazing kids. You are always in my heart.
You might want to visit www.PacktPub.com for support files and downloads related to your book.
Did you know that Packt offers eBook versions of every book published, with PDF and ePub files available? You can upgrade to the eBook version at www.PacktPub.com and as a print book customer, you are entitled to a discount on the eBook copy. Get in touch with us at <[email protected]> for more details.
At www.PacktPub.com, you can also read a collection of free technical articles, sign up for a range of free newsletters, and receive exclusive discounts and offers on Packt books and eBooks.
http://PacktLib.PacktPub.com
Do you need instant solutions to your IT questions? PacktLib is Packt's online digital book library. Here, you can access, read, and search across Packt's entire library of books.
If you have an account with Packt at www.PacktPub.com, you can use this to access PacktLib today and view nine entirely free books. Simply use your login credentials for immediate access.
Testing is essential for any activity to succeed; this applies to software as well. It not only covers verification but also the validation of the software. Commonly used testing practices include unit and functional testing that validates the needed functionality. However, manual efforts by testers or stakeholders are required to verify that the software being tested works as desired, as part of the software acceptance process.
As software has grown both in size and amount over the years, the acceptance testing process has become automated, leaving behind vast information in the form of audit trails of tests that need to be made available to the user at a glance and without which the purpose of acceptance test automation is defeated.
The Robot framework provides this missing link that integrates with the testing tool used for performing acceptance testing over the software or the "system under test" and structures this execution into discrete structures of tests arranged in a proper hierarchical manner; this not only results in execution in the desired manner, but also generates orderly reports.
Being an open source framework, this tool does not limit you to simply performing acceptance testing in a hierarchical manner and generating automated reports, but also allows you to customize it and create your own tool or even use it with other tools as part of a custom test environment setup required for your team.
Chapter 1, Getting Started with the Robot Framework, explains the need for acceptance test driven development, offers a high-level overview, and gives different methods of installation of the Robot Framework tool. It also discusses the various commands available for the user to interact with the framework and demonstrates simple test project creation and execution to the user.
Chapter 2, Configuring a Test Project, explains the test hierarchies and covers the different files and tables used in the framework as well as different syntax options to write the test files. It explains the commonly used test practices and explains how information can be re-used within the tests.
Chapter 3, Further Test Customization, covers test re-use, connectivity to external data sources and test templates, and user-defined keywords. It also provides different test writing styles and offers comparison with some other famous behavior-driven test tools.
Chapter 4, Extending the Framework, demonstrates real-world testing challenges and offers practical ways of using various built-in and external libraries to solve these challenges. It covers both the Web-based and desktop testing through object-oriented as well as image-based tests. In the absence of a compatible testing library, it also demonstrates the creation and integration of a custom written library.
Chapter 5, Generating Reports, covers the generated output of the tool in detail and offers different ways to customize the reports as well as the logs generated through the built-in as well as custom mechanisms. It also encourages the user to leverage the source code to create a customized reporting mechanism in the existing framework.
In order to use the Robot Framework, you first need to install Python (the examples have been tested against 2.7, but you are free to use any version between Python 2.7 or 3), which might be installed if you are using a popular Linux distro or Mac OS X as your OS. Apart from Python, you can also install Jython and IronPython that can be used to run Python-based applications and tools such as the Robot Framework on JDK or .NET Framework runtime. A few examples do require explicit use of Jython, but the rest of the available environments can be used with any Python-based runtime. To install third party tools, or for easier installation, it is recommended to use easy_install Python module. Installations for tools/frameworks needed alongside testing with the Robot Framework are provided where necessary.
As this book is focused on a testing tool, it primarily targets the testers. However, given the necessities of creating an in-house flexible testing tool, a hands-on Python development is also needed to modify and develop a testing framework to suit one's needs. Similar to DevOps movement, developers today are seeking ways to look beyond test and behavior-driven development, and the testers are also required to be more productive through means of automation. In this book, you will have to wear both the developer's and tester's hat in various situations in order to gain knowledge of this tool's working from both the perspectives.
