Skip to content

Commit

Permalink
Support coffeescript option
Browse files Browse the repository at this point in the history
cucumber-js 0.3.3 added support for coffee script snippets.  This
allows that flag to be set in the gruntfile.
  • Loading branch information
Bochenski committed Feb 28, 2014
1 parent 04a2c27 commit 0b9a570
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,12 @@ but you can not open source the contributions.

Example: `modulePath: "../../custom_libs/cucumberjs/lib/cucumber.js"`

#### coffee
Type: `Boolean`

Default: `false`

When true, cucumberjs will output code snippets in coffeescript

### Usage Examples

Expand Down
5 changes: 5 additions & 0 deletions tasks/cucumber-js-task.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ module.exports = function (grunt) {
var tags = options.tags;
var format = options.format;
var modulePath = options.modulePath;
var coffee = options.coffee;

grunt.verbose.writeflags(options, 'Options');

Expand Down Expand Up @@ -62,6 +63,10 @@ module.exports = function (grunt) {
execOptions.push(format);
}

if (coffee) {
execOptions.push('--coffee');
}

var cucumberPath = 'cucumber';
if (! _.isEmpty(modulePath)) {
cucumberPath = modulePath;
Expand Down

0 comments on commit 0b9a570

Please sign in to comment.