Added rule and annotation for expected exception.