Skip to content

Commit

Permalink
v.0.1.1
Browse files Browse the repository at this point in the history
-Added a configuration option to change the path to the Cucumber.js library, enabling control over the path lets developers use customized versions of Cucumber.js
-Updated version number to 0.1.1
-Updated README with new config option

Signed-off-by: Omar Gonzalez <[email protected]>
  • Loading branch information
s9tpepper committed Aug 9, 2012
1 parent aba3b36 commit e12cb53
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Then add this line to your project's `grunt.js` gruntfile:
```javascript
grunt.initConfig({
cucumberjs: {
executable: "../path/to/custom/cucumberjs",
features: "path/to/features",
steps: "path/to/step_definitions",
tags: "@dev"
Expand Down
1 change: 1 addition & 0 deletions grunt.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ module.exports = function (grunt) {
globals: {}
},
cucumberjs: {
executable: "../node_modules/cucumber/lib/cucumber.js", /* Relative to /tasks folder */
features: "features",
steps: "features/step_definitions"
}
Expand Down
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.1.0",
"version" : "0.1.1",
"homepage" : "https://github.com/s9tpepper/grunt-cucumber-js",
"author" : {
"name" : "Omar Gonzalez",
Expand Down
3 changes: 2 additions & 1 deletion tasks/cucumber-js-task.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ module.exports = function (grunt) {

grunt.registerTask("cucumberjs", "Runs cucumber.js", function () {

var Cucumber = require('cucumber');
var cucumberPath = grunt.config("cucumberjs.executable") || 'cucumber';
var Cucumber = require(cucumberPath);

var features = grunt.config("cucumberjs.features") || 'features';
var steps = grunt.config("cucumberjs.steps") || 'features/step_definitions';
Expand Down

0 comments on commit e12cb53

Please sign in to comment.