From 545db260ee27e7121eed42e963973038013b4bd4 Mon Sep 17 00:00:00 2001 From: ronkorving Date: Sun, 14 Feb 2016 16:01:02 +0900 Subject: [PATCH] doc: Explain opts in t.test --- readme.markdown | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/readme.markdown b/readme.markdown index 56503537..18b87d24 100644 --- a/readme.markdown +++ b/readme.markdown @@ -261,12 +261,14 @@ Assert that the function call `fn()` throws an exception. `expected`, if present Assert that the function call `fn()` does not throw an exception. -## t.test(name, cb) +## t.test(name, [opts], cb) Create a subtest with a new test handle `st` from `cb(st)` inside the current test `t`. `cb(st)` will only fire when `t` finishes. Additional tests queued up after `t` will not be run until all subtests finish. +You may pass the same options that [`test()`](#testname-opts-cb) accepts. + ## t.comment(message) Print a message without breaking the tap output. (Useful when using e.g. `tap-colorize` where output is buffered & `console.log` will print in incorrect order vis-a-vis tap output.)