static void withMessage(String message,Runnable r){
  try {
    r.run();
  }
 catch (  ComparisonFailure cmp) {
    ComparisonFailure ex=new ComparisonFailure(message + ": " + cmp.getMessage(),cmp.getExpected(),cmp.getActual());
    ex.setStackTrace(cmp.getStackTrace());
    throw ex;
  }
catch (  AssertionError err) {
    AssertionError ex=new AssertionError(message + ": " + err.getMessage(),err.getCause());
    ex.setStackTrace(err.getStackTrace());
    throw ex;
  }
catch (  RuntimeException|Error err) {
    throw new RuntimeException(message + ": " + err.getMessage(),err);
  }
}

static void withMessage ( String message , Runnable r ) { try { r . run ( ) ; } catch ( ComparisonFailure cmp ) { ComparisonFailure ex = new ComparisonFailure ( message + ": " + cmp . getMessage ( ) , cmp . getExpected ( ) , cmp . getActual ( ) ) ; ex . setStackTrace ( cmp . getStackTrace ( ) ) ; throw ex ; } catch ( AssertionError err ) { AssertionError ex = new AssertionError ( message + ": " + err . getMessage ( ) , err . getCause ( ) ) ; ex . setStackTrace ( err . getStackTrace ( ) ) ; throw ex ; } catch ( RuntimeException | Error err ) { throw new RuntimeException ( message + ": " + err . getMessage ( ) , err ) ; } }
run the runnable automatically adding given message to every failed assertion
