Extend ExpectedException's documentation and fix #687.