Skip to content

Instantly share code, notes, and snippets.

@thehig
Last active May 16, 2017 17:22
Show Gist options
  • Save thehig/f11215f1a16594d9edc5068b362a4dab to your computer and use it in GitHub Desktop.
Save thehig/f11215f1a16594d9edc5068b362a4dab to your computer and use it in GitHub Desktop.
js: Mocha Chai Coffee Node Test Harness
/*
* NPM package.json template
* Replace:
* $PROJECTNAME$ eg: package-json-sample (Must be valid npm project name)
* $GITHUBUSERNAME$ eg: thehig
* $AUTHOR$ eg: David Higgins <[email protected]>
* $TESTPATTERN$ eg: specs/unit/*.coffee
*/
{
"name": "$PROJECTNAME$",
"author": "$AUTHOR$",
"version": "0.0.1",
"repository": {
"type": "git",
"url": "git+https://github.com/$GITHUBUSERNAME$/$PROJECTNAME$.git"
},
"bugs": {
"url": "https://github.com/$GITHUBUSERNAME$/$PROJECTNAME$/issues"
},
"homepage": "https://github.com/$GITHUBUSERNAME$/$PROJECTNAME$#readme",
"dependencies": {
},
"devDependencies": {
"chai": "*",
"mocha": "*",
"coffee-script": "*",
},
"scripts": {
"test": "mocha --require coffee-script/register --compilers coffee:coffee-script/register $TESTPATTERN$ --bail --timeout 30000",
"test-debug": "mocha --debug-brk --require coffee-script/register --compilers coffee:coffee-script/register $TESTPATTERN$ --bail --timeout 30000",
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment