@Override
 public boolean isTakingAction(Event event, TestResult result) {
   if (event instanceof After) {
     if (configuration.getTakeAfterTest()) {
       return true;
     }
     if (result.getStatus() == Status.FAILED && configuration.getTakeWhenTestFailed()) {
       return true;
     }
   }
   return false;
 }
 @Override
 public boolean isTakingAction(Event event) {
   return event instanceof Before && configuration.getTakeBeforeTest();
 }