fail method java code example
Example: fail method java
try{
// do stuff...
fail("Exception not thrown");
}catch(Exception e){
assertTrue(e.hasSomeFlag());
}
try{
// do stuff...
fail("Exception not thrown");
}catch(Exception e){
assertTrue(e.hasSomeFlag());
}