O'Reilly logo

The Cucumber Book, 2nd Edition by Steve Tooke, Aslak Hellesoy, Matt Wynne

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating a Feature

Cucumber tests are grouped into features. We use this name because we want them to describe the features that a user will be able to enjoy when using our program. The first thing we need to do is make a directory where we’ll store our new program along with the features we’ll be writing for it.

 $ ​​mkdir​​ ​​calculator
 $ ​​cd​​ ​​calculator

We’re going to let Cucumber guide us through the development of our calculator program, so let’s start by running cucumber in this empty folder:

 $ ​​cucumber
 No such file or directory - features. Please create a features directory
 to get started.

Since we didn’t specify any command-line arguments, Cucumber has assumed that we’re using the conventional features folder to store ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required