You probably want to assert that it throws the expected exception.  There's a function for that, by the way: assert.throws(cb, expected) where 'expected' is e.g. TypeError, a regex or a string.