Methods Summary |
---|
public static void | assertClassAssignability(java.lang.Class source, java.lang.Class target)
if ( !target.isAssignableFrom( source ) ) {
throw new AssertionFailedError(
"Classes were not assignment-compatible : source<" + source.getName() +
"> target<" + target.getName() + ">"
);
}
|
public static void | assertElementTypeAssignability(java.util.Collection collection, java.lang.Class clazz)
Iterator itr = collection.iterator();
while ( itr.hasNext() ) {
assertClassAssignability( itr.next().getClass(), clazz );
}
|
public java.lang.String | fullTestName()
return this.getClass().getName() + "#" + this.getName();
|
protected void | reportSkip(java.lang.String reason, java.lang.String testDescription)
SkipLog.LOG.warn( "*** skipping [" + fullTestName() + "] - " + testDescription + " : " + reason, new Exception() );
|
public void | runBare()runBare overridden in order to apply FailureExpected validations
as well as start/complete logging
final boolean doValidate = getName().endsWith( "FailureExpected" ) && Boolean.getBoolean( "hibernate.test.validatefailureexpected" );
try {
log.info( "Starting test [" + fullTestName() + "]" );
super.runBare();
if ( doValidate ) {
fail( "Test marked as FailureExpected, but did not fail!" );
}
}
catch( Throwable t ) {
if ( doValidate ) {
skipExpectedFailure( t );
}
else {
throw t;
}
}
finally {
log.info( "Completed test [" + fullTestName() + "]" );
}
|
protected void | skipExpectedFailure(java.lang.Throwable error)
reportSkip( "ignoring *FailuredExpected methods", "Failed with: " + error.toString() );
|