diff options
author | Robert Kowalski <rok@kowalski.gd> | 2014-04-20 15:32:42 +0200 |
---|---|---|
committer | Robert Kowalski <rok@kowalski.gd> | 2014-04-24 20:32:08 +0200 |
commit | 12485a0090fb212e4a6dc49435fe2c0ab07daa79 (patch) | |
tree | 7ee223225ccb86f0f16efec0c0a50702e36588f6 | |
parent | abeaf26c5efda279dcc4ad438d13e2f496daa38a (diff) | |
download | couchdb-12485a0090fb212e4a6dc49435fe2c0ab07daa79.tar.gz |
Fauxton: test for globals
As a developer, I don't want to accidentally pollute the global
namespace and rely on global state.
-rw-r--r-- | src/fauxton/Gruntfile.js | 36 |
1 files changed, 34 insertions, 2 deletions
diff --git a/src/fauxton/Gruntfile.js b/src/fauxton/Gruntfile.js index c650b9fac..8ffb2f8a6 100644 --- a/src/fauxton/Gruntfile.js +++ b/src/fauxton/Gruntfile.js @@ -164,7 +164,39 @@ module.exports = function(grunt) { options: { scripturl: true, evil: true, - expr: true + expr: true, + undef: true, + globals: { + document: true, + window: true, + location: true, + alert: true, + console: true, + clearInterval: true, + setInterval: true, + setTimeout: true, + prompt: true, + confirm: true, + + jQuery: true, + Backbone: true, + $: true, + _: true, + require: true, + module: true, + sinon: true, + it: true, + describe: true, + beforeEach: true, + afterEach: true, + before: true, + after: true, + define: true, + + Spinner: true, + prettyPrint: true + + } } }, @@ -242,7 +274,7 @@ module.exports = function(grunt) { couchserver: couchserver_config, watch: { - js: { + js: { files: helper.watchFiles(['.js'], ["./app/**/*.js", '!./app/load_addons.js',"./assets/**/*.js", "./test/**/*.js"]), tasks: ['watchRun'], }, |