File tree 1 file changed +11
-10
lines changed
1 file changed +11
-10
lines changed Original file line number Diff line number Diff line change @@ -17,17 +17,18 @@ synopsis
17
17
var vows = require('vows'),
18
18
assert = require('assert');
19
19
20
- vows.describe('Deep Thought').addVows(function () {
21
- question('what is the answer to the universe?').addVow(function (answer) {
22
- assert.equals(answer, 42);
23
- }, 'it should know the answer to the ultimate question of life');
24
- });
20
+ vows.describe('Deep Thought').addVows({
21
+ 'An instance of DeepThought': {
22
+ topic: new DeepThought,
25
23
26
- In the example above, ` question() ` would be a function which returns an ` EventEmitter ` .
27
- When the ` "success" ` event is emitted, the function passed to ` addVow ` is run,
28
- and the results output to the console.
24
+ 'should know the answer to the ultimate question of life': function (deepThought) {
25
+ assert.equal (deepThought.question('what is the answer to the universe?'), 42);
26
+ }
27
+ }
28
+ });
29
29
30
- Vows are run as soon as the promise completes, so the order in which they are run is undefined.
30
+ Documenation coming soon. For now, have a look at the tests in < http://github.com/cloudhead/resourcer > to
31
+ get an idea.
31
32
32
33
installation
33
34
------------
@@ -69,7 +70,7 @@ writing specs
69
70
}
70
71
}
71
72
}
72
- });
73
+ }).run() ;
73
74
74
75
assertion macros
75
76
----------------
You can’t perform that action at this time.
0 commit comments