lundi 26 janvier 2015

Junit to test if the method call is made

I've a transaction class which has a validate method. There is a condition in the method which when satisfied will not be calling an alert notification method. The alert notification method will only be called when the check condition failed(Condition is false, call the alert and notify the user). I want to test from a Junit test if that alert method gets called or not. Could someone advise how to proceed as I'm new to Junits


Aucun commentaire:

Enregistrer un commentaire