Many projects use a build tool to perform common tasks. For Ruby projects, Rake is the de facto build tool. Cucumber has a Rake task that makes it easy to run Cucumber from Rake. If you are using Cucumber-Rails, which we describe in Chapter 14, Bootstrapping Rails, you will have Rake tasks set up automatically.
If you are not using Rake, it’s still easy to set it up yourself. Try adding this to a Rakefile in the root of your project:
|||Cucumber::Rake::Task.new # defines a task named cucumber|
Now you can run your Cucumber features from Rake:
|||$ rake cucumber|
Profiles from cucumber.yml will be picked up when you run Cucumber from Rake, but you can also define Cucumber ...