Sotaro KARASAWA 11 лет назад
Родитель
Сommit
afa52cb72b
3 измененных файлов с 35 добавлено и 3 удалено
  1. 13 0
      circle.yml
  2. 9 3
      package.json
  3. 13 0
      test/test.js

+ 13 - 0
circle.yml

@@ -0,0 +1,13 @@
+deployment:
+  demo:
+    branch: master
+    heroku:
+      appname: crowi-demo
+  dev:
+    branch: master
+    heroku:
+      appname: crowi-dev
+  strk:
+    branch: master
+    heroku:
+      appname: strk-wiki

+ 9 - 3
package.json

@@ -34,13 +34,13 @@
     "express-session": "~1.9.3",
     "facebook-node-sdk": "=0.1.10",
     "googleapis": "=0.4.7",
-    "grunt": "~0.4.1",
+    "grunt": "~0.4.5",
     "grunt-cli": "~0.1.13",
     "grunt-contrib-concat": "~0.5.0",
     "grunt-contrib-jshint": "^0.10.0",
     "grunt-contrib-uglify": "~0.2.2",
     "grunt-contrib-watch": "~0.5.3",
-    "grunt-sass": "~0.14.1",
+    "grunt-sass": "~0.17.0",
     "mongoose": "=3.8.14",
     "mongoose-paginate": "~3.1.0",
     "nodemailer": "~1.2.2",
@@ -51,7 +51,12 @@
     "swig": "=1.3.2",
     "time": "=0.10.0"
   },
-  "devDependencies": {},
+  "devDependencies": {
+    "chai": "^1.10.0",
+    "mocha": "~2.1.0",
+    "mongoose-mock": "~0.4.0",
+    "proxyquire": "~1.3.0"
+  },
   "license": [
     {
       "type": "MIT",
@@ -60,6 +65,7 @@
   ],
   "scripts": {
     "start": "node app.js",
+    "test": "./node_modules/.bin/mocha",
     "postinstall": "./node_modules/.bin/bower cache clean && ./node_modules/.bin/bower install && ./node_modules/.bin/grunt"
   },
   "env": {

+ 13 - 0
test/test.js

@@ -0,0 +1,13 @@
+// sample
+
+var assert = require("assert");
+
+describe('Array', function(){
+  describe('#indexOf()', function(){
+    it('should return -1 when the value is not present', function(){
+      assert.equal(-1, [1,2,3].indexOf(5));
+      assert.equal(-1, [1,2,3].indexOf(0));
+    })
+  })
+})
+