Last active
August 29, 2015 14:03
-
-
Save rwjblue/356faa8a2ca3cb08e9f9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var runCommand = require('../helpers/run-command'); | |
var childProcess = require('child_process'); | |
function ifHasGit(callback) { | |
return new Promise(function(resolve) { | |
childProcess.exec('git --version', function(error){ | |
if (!!error) { | |
callback(); | |
} | |
}) | |
}) | |
} | |
it('calls git init when git is present', function() { | |
return ifHasGit(function(){ | |
// do your actual assertions here | |
}) | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment