throws

abstract var throws: JsFunction<*, *>(source)

Identical to the throws function from the node:assert module, but bound to the test context.