Running the Cucumber suite
Now that we are familiar with the project layout, let's execute some tests. To start, let's install the Cucumber gem. So, run the following command in the terminal:
gem install cucumber
After the gem has been installed, we have several commands we can use to run our tests from the root of the working directory:
To execute the whole suite in the
defaultprofile, we simply run the following command in our terminal from the root of our workspace:cucumberThe Cucumber gem will automatically find the
featuresdirectory. If your features are located in another directory, you will need to specify the path to that directory like this:cucumber some/other/directoryUse the
-pflag to specify a different profile at the time of execution. To run our whole test suite in theciprofile, we can use this command:cucumber –p ciWe do not need to execute the whole test suite every single time. If we want to run only a single file or all the feature files in a directory, we just...