Skip to content

Instantly share code, notes, and snippets.

@mrvisser
Created November 27, 2012 16:17
Show Gist options
  • Save mrvisser/4155177 to your computer and use it in GitHub Desktop.
Save mrvisser/4155177 to your computer and use it in GitHub Desktop.
MOCHA_GREP
diff --git a/grunt.js b/grunt.js
index 3412fd7..8b35d4a 100644
--- a/grunt.js
+++ b/grunt.js
@@ -1,6 +1,7 @@
module.exports = function(grunt) {
var shell = require('shelljs');
+ var grep = process.env['MOCHA_GREP'] || undefined;
// Project configuration.
grunt.initConfig({
@@ -49,7 +50,8 @@ module.exports = function(grunt) {
options: {
timeout: 20000,
ignoreLeaks: true,
- reporter: 'spec'
+ reporter: 'spec',
+ grep: grep
}
};
grunt.config.set('simplemocha.' + module, config);
@@ -63,8 +65,7 @@ module.exports = function(grunt) {
options: {
timeout: 20000,
ignoreLeaks: true,
- reporter: 'spec',
- grep: grep
+ reporter: 'spec'
}
};
grunt.config.set('simplemocha.grep-' + grep, config);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment