Skip to content

Commit

Permalink
Merge pull request #5 from felipecvo/master
Browse files Browse the repository at this point in the history
Fix exit status code
  • Loading branch information
s9tpepper committed Sep 9, 2013
2 parents 1911885 + 1c2bd5c commit 1256f3b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "grunt-cucumber",
"description": "Grunt task for running Cucumber.js",
"version": "0.2.1",
"version": "0.2.2",
"homepage": "https://github.com/s9tpepper/grunt-cucumber-js",
"author": {
"name": "Omar Gonzalez",
Expand Down
9 changes: 4 additions & 5 deletions tasks/cucumber-js-task.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,12 @@ module.exports = function (grunt) {
var tags = options.tags;
var format = options.format;
var executable = options.executable;

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

var callback = function(succeeded) {
var code = succeeded ? 0 : 1;
var exitFunction = function() {
done(code);
done(succeeded);
};

// --- exit after waiting for all pending output ---
Expand All @@ -42,7 +41,7 @@ module.exports = function (grunt) {


var execOptions = ['node', 'node_modules/.bin/cucumber-js'];

var _ = grunt.util._;
if (! _.isEmpty(files)) {
execOptions = execOptions.concat(files);
Expand All @@ -62,7 +61,7 @@ module.exports = function (grunt) {
execOptions.push('-f');
execOptions.push(format);
}

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

0 comments on commit 1256f3b

Please sign in to comment.