assert-in-order
Assert a group of assertions are performed in order.
Synopsis
var assert = var inOrder = var assertions = 'ok' 'first assertion' 'equal' 'second assertion'
Each assertion should be an array whose first item is a method name. Any
additional items are appended to the argument list when the assertion is
called. For example, group[0](true)
is equivalent to
assert.ok(true, 'first assertion')
with an additional ordering check.
var group1 = assert // These passgroup10truegroup111 1 // These don'ttry var group2 = group211 1 group20true catch err assert // live life on the edge by abusing ordered object keys:group3 = assert group3group3
The ordering checks do not change the number of assertions that will be run so you can use this with [tap][] or [tape][] and test plans:
'Assertion ordering' { var group = t group group}
License
MIT