Your customers want rock-solid, bug-free software that does exactly what they expect it to do. Yet they can't always articulate their ideas clearly enough for you to turn them into code. You need Cucumber: a testing, communication, and requirements tool-all rolled into one. All the code in this book is updated for Cucumber 2.4, Rails 5, and RSpec 3.5. Express your customers' wild ideas as a set of clear, executable specifications that everyone on the team can read. Feed those examples into Cucumber and let it guide your development. Build just the right code to keep your customers happy. You can use Cucumber to test almost any system or any platform. Get started by using the core features of Cucumber and working with Cucumber's Gherkin DSL to describe-in plain language-the behavior your customers want from the system. Then write Ruby code that interprets those plain-language specifications and checks them against your application. Next, consolidate the knowledge you've gained with a worked example, where you'll learn more advanced Cucumber techniques, test asynchronous systems, and test systems that use a database. Recipes highlight some of the most difficult and commonly seen situations the authors have helped teams solve. With these patterns and techniques, test Ajax-heavy web applications with Capybara and Selenium, REST web services, Ruby on Rails applications, command-line applications, legacy applications, and more. Written by the creator of Cucumber and the co-founders of Cucumber Ltd., this authoritative guide will give you and your team all the knowledge you need to start using Cucumber with confidence. What You Need: Windows, Mac OS X (with XCode) or Linux, Ruby 1.9.2 and upwards, Cucumber 2.4, Rails 5, and RSpec 3.5
You can test just about anything with Cucumber. We certainly have, and in Cucumber Recipes we'll show you how to apply our hard-won field experience to your own projects. Once you've mastered the basics, this book will show you how to get the most out of Cucumber--from specific situations to advanced test-writing advice. With over forty practical recipes, you'll test desktop, web, mobile, and server applications across a variety of platforms. This book gives you tools that you can use today to automate any system that you encounter, and do it well. The Cucumber Book showed you how your team can work together to write executable specifications--documents that tell a clear story and also happen to be working test code. We'll arm you with ready-rolled solutions to real-world problems: your tests will run faster, read more clearly, and work in any environment. Our first tips will help you fit Cucumber into your workflow. Powerful filters will tame tables full of test data, transforming them into the format your application needs. Custom output formatters will generate reports for any occasion. Continuous Integration servers will run your Cucumber tests every time the code changes. Next, you'll find recipes tailored to the platform you're running on. Ever wanted to know how to test a Grails app from Cucumber? Need to put a Windows program through its paces? How about a mobile app running on Android or iOS? We'll show you how to do all of these. Throughout the book, you'll see how to make Cucumber sing as you interoperate with different platforms, languages, and environments. From embedded circuits to Python and PHP web apps, Cucumber has something for you. What You Need: You'll need basic working knowledge of Cucumber and Ruby. Individual recipes may have additional requirements; for example, a recipe on Windows automation might pull in an open source GUI driver. We've written the recipes for compatibility with Ruby 1.9.3 and 1.8.7, plus Cucumber 1.1.4. Other versions may work as well, but these are the ones we test with.
Author: Wayne Ye
Publisher: Packt Publishing Ltd
Release Date: 2013-04-24
Filled with practical, step-by-step instructions and clear explanations for the most important and useful tasks. This standard How-to guide explains the essence of Cucumber, describing how to write Cucumber features to drive development in a real project, and also describe many pro tips for writing good Cucumber features and steps.Instant Cucumber BDD How-to is great for an Agile software development team that wants to adopt a behaviour-driven process using Cucumber. It assumes that the team is passionate in reducing communication gaps between developers and product managers, ensuring the development is always on the right track and always focused on minimum marketable value.
With Acceptance Test-Driven Development (ATDD), business customers, testers, and developers can collaborate to produce testable requirements that help them build higher quality software more rapidly. However, ATDD is still widely misunderstood by many practitioners. ATDD by Example is the first practical, entry-level, hands-on guide to implementing and successfully applying it. ATDD pioneer Markus Gärtner walks readers step by step through deriving the right systems from business users, and then implementing fully automated, functional tests that accurately reflect business requirements, are intelligible to stakeholders, and promote more effective development. Through two end-to-end case studies, Gärtner demonstrates how ATDD can be applied using diverse frameworks and languages. Each case study is accompanied by an extensive set of artifacts, including test automation classes, step definitions, and full sample implementations. These realistic examples illuminate ATDD’s fundamental principles, show how ATDD fits into the broader development process, highlight tips from Gärtner’s extensive experience, and identify crucial pitfalls to avoid. Readers will learn to Master the thought processes associated with successful ATDD implementation Use ATDD with Cucumber to describe software in ways businesspeople can understand Test web pages using ATDD tools Bring ATDD to Java with the FitNesse wiki-based acceptance test framework Use examples more effectively in Behavior-Driven Development (BDD) Specify software collaboratively through innovative workshops Implement more user-friendly and collaborative test automation Test more cleanly, listen to test results, and refactor tests for greater value If you’re a tester, analyst, developer, or project manager, this book offers a concrete foundation for achieving real benefits with ATDD now–and it will help you reap even more value as you gain experience.
Describes a method of effectively specifying, testing, and delivering software, covering such topics as documentation, process patterns, and automation, along with case studies from a variety of firms.
This book is intended for business and development personnel who want to use Cucumber for behavior-driven development and test automation. Readers with some familiarity with Cucumber will find this book of most benefit. Since the main objective of this book is to create test automation frameworks, previous experience in automation will be helpful.
Author: Gáspár Nagy
Release Date: 2018-02-07
Written by the creator of SpecFlow and the author of The Cucumber for Java Book, this book provides inside information on how to get the most out of the discovery phase of Behaviour Driven Development (BDD). This practical guide demonstrates good collaboration techniques, illustrated by concrete examples. This book is written for everyone involved in the specification and delivery of software (including product owners, business analysts, developers, and testers). The book starts by explaining the reasons BDD exists in the first place and describes techniques for getting the most out of collaboration between business and delivery team members. This is the first in the BDD Books series that will guide you through the entire development process, including specific technical practices needed to successfully drive development using collaboratively-authored specifications and living documentation.
Author: Kent Beck
Publisher: Addison-Wesley Professional
Release Date: 2003
Write clean code that works with the help of this groundbreaking software method. Example-driven teaching is the basis of Beck's step-by-step instruction that will have readers using TDD to further their projects.
Specification by Example and Gherkin offer programmers, designers, and managers an inclusive environment for clear communication, discovering requirements, and building a documentation system. Writing Great Specifications is an example-rich tutorial that teaches readers how to write good Gherkin specification documents that take advantage of Specification by Example's benefits. Engineers and testers will find it helpful in striking a stronger chord with non-technical audiences through automated specifications. Purchase of the print book includes a free eBook in PDF, Kindle, and ePub formats from Manning Publications.
Author: Richard Lawrence
Publisher: Addison-Wesley Professional
Release Date: 2016-03-09
Agile software development teams are seeking better ways to create business-facing automated tests that support the development of the right product. Cucumber is rapidly becoming the most popular tool for accomplishing this objective – but, until now, no book has covered Behavior-Driven Development (BDD) practices and tools in sufficient depth. Teams have been forced to keep reinventing the wheel, or else to hire one of a handful of consultants at great expense. Behavior-Driven Development with Cucumber fills that gap. ¿ Richard Lawrence and Paul Rayner begin by illuminating ATDD's value, and showing how it can help you produce better software with less pain. Next, they present a complete BDD/Cucumber reference and tutorial that provides a common language for software customers and team members alike. Lawrence and Rayner thoroughly explain the role of each team member and stakeholder, with a particularly insightful emphasis on non-developers. Next, they show how to automate functional tests for web, console, native client, legacy, and other applications on the Ruby, Java, and .NET. platforms. To complement the Web's existing Ruby-oriented Cucumber resources, the authors provide even more Java (Cuke4Duke) and C# (Cuke4Nuke) examples. ¿ Throughout, you'll find concrete examples and hands-on exercises based on the authors' extensive experience teaching BDD to software professionals and helping software organizations successfully implement BDD strategies.
Within the framework of Acceptance Test-Driven-Development (ATDD), customers, developers, and testers collaborate to create acceptance tests that thoroughly describe how software should work from the customer’s viewpoint. By tightening the links between customers and agile teams, ATDD can significantly improve both software quality and developer productivity. This is the first start-to-finish, real-world guide to ATDD for every agile project participant. Leading agile consultant Ken Pugh begins with a dialogue among a customer, developer, and tester, explaining the “what, why, where, when, and how” of ATDD and illuminating the experience of participating in it. Next, Pugh presents a practical, complete reference to each facet of ATDD, from creating simple tests to evaluating their results. He concludes with five diverse case studies, each identifying a realistic set of problems and challenges with proven solutions. Coverage includes • How to develop software with fully testable requirements • How to simplify and componentize tests and use them to identify missing logic • How to test user interfaces, service implementations, and other tricky elements of a software system • How to identify requirements that are best handled outside software • How to present test results, evaluate them, and use them to assess a project’s overall progress • How to build acceptance tests that are mutually beneficial for development organizations and customers • How to scale ATDD to large projects