aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Finlay <dan@danfinlay.com>2016-06-22 05:01:40 +0800
committerDan Finlay <dan@danfinlay.com>2016-06-22 05:01:40 +0800
commit1cafdb8b1dbe06e29441316789a84720a897eeb3 (patch)
treefdc1aeda5a304507081f887b04a7dddb6b1a6204
parent8fde8a8921135112ccfdd13ce6b009755b5f71ed (diff)
downloadtangerine-wallet-browser-1cafdb8b1dbe06e29441316789a84720a897eeb3.tar
tangerine-wallet-browser-1cafdb8b1dbe06e29441316789a84720a897eeb3.tar.gz
tangerine-wallet-browser-1cafdb8b1dbe06e29441316789a84720a897eeb3.tar.bz2
tangerine-wallet-browser-1cafdb8b1dbe06e29441316789a84720a897eeb3.tar.lz
tangerine-wallet-browser-1cafdb8b1dbe06e29441316789a84720a897eeb3.tar.xz
tangerine-wallet-browser-1cafdb8b1dbe06e29441316789a84720a897eeb3.tar.zst
tangerine-wallet-browser-1cafdb8b1dbe06e29441316789a84720a897eeb3.zip
Add linting to our mocha suite
-rw-r--r--package.json3
-rw-r--r--test/unit/linting_test.js9
2 files changed, 11 insertions, 1 deletions
diff --git a/package.json b/package.json
index 8c1f119cb..31ae0db95 100644
--- a/package.json
+++ b/package.json
@@ -5,7 +5,7 @@
"private": true,
"scripts": {
"start": "gulp dev",
- "test": "mocha --require test/helper.js --compilers js:babel-register --recursive && gulp lint",
+ "test": "mocha --require test/helper.js --compilers js:babel-register --recursive",
"watch": "mocha watch --compilers js:babel-register --recursive"
},
"browserify": {
@@ -89,6 +89,7 @@
"jshint-stylish": "~0.1.5",
"lodash.assign": "^4.0.6",
"mocha": "^2.4.5",
+ "mocha-eslint": "^2.1.1",
"mocha-jsdom": "^1.1.0",
"mocha-sinon": "^1.1.5",
"sinon": "^1.17.3",
diff --git a/test/unit/linting_test.js b/test/unit/linting_test.js
new file mode 100644
index 000000000..27b4b2b1e
--- /dev/null
+++ b/test/unit/linting_test.js
@@ -0,0 +1,9 @@
+// LINTING:
+const lint = require('mocha-eslint');
+const lintPaths = ['app/**/*.js', 'ui/**/*.js', '!node_modules/**', '!dist/**', '!docs/**', '!app/scripts/chromereload.js']
+
+const lintOptions = {
+ strict: true,
+}
+
+lint(lintPaths, lintOptions) \ No newline at end of file