]> khamidou — GitHub mirrors - electron.git/commitdiff
Add spec for q.
authorCheng Zhao <zcbenz@gmail.com>
Fri, 10 Jan 2014 07:19:08 +0000 (15:19 +0800)
committerCheng Zhao <zcbenz@gmail.com>
Fri, 10 Jan 2014 07:58:14 +0000 (15:58 +0800)
package.json
spec/modules-spec.coffee

index 7658c557e351932c878aa978449777f7a837337f..825295123f31a41fd9b6831d9fcfa446734ae689 100644 (file)
@@ -7,6 +7,7 @@
     "coffeelint": "~0.6.1",
     "mocha": "~1.13.0",
     "pathwatcher": "0.13.0",
+    "q": "0.9.7",
     "walkdir": "~0.0.7",
     "runas": "0.3.0",
     "formidable": "~1.0.14",
index ef4d742b17db00e75321f5e4ff1ee01337520046..165449638e2fdb518090e28df7f95bcec28554d9 100644 (file)
@@ -30,3 +30,13 @@ describe 'third-party module', ->
           watcher.close()
           done()
         fs.writeFileSync file, 'content2'
+
+  describe 'q', ->
+    Q = require 'q'
+
+    describe 'Q.when', ->
+      it 'emits the fullfil callback', (done) ->
+        Q(true).then (val) ->
+          assert.equal val, true
+          console.log 'test'
+          done()