How to write unit test for this block of code
if (!isVisible()) {
throw new IllegalStateException("Not in xyz page");
}
return this.isAttached(DOT_ID);
If isVisible()
is mocked to return false
then how to write the unit test for the exception statement
Aucun commentaire:
Enregistrer un commentaire