exception

public T exception()(source)

If the test resulted in the expected expected exception}, this methods returns this exception. Otherwise this method returns null.

Return

the exception or null