uk.org.retep.test.RetepClassRunner Maven / Gradle / Ivy
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package uk.org.retep.test;
import org.apache.log4j.xml.DOMConfigurator;
import org.junit.runners.BlockJUnit4ClassRunner;
import org.junit.runners.model.InitializationError;
/**
*
* @author peter
*/
public class RetepClassRunner
extends BlockJUnit4ClassRunner
{
static
{
DOMConfigurator.configure( RetepClassRunner.class.getResource( "log4j.xml" ) );
}
public RetepClassRunner( final Class testClass )
throws InitializationError
{
super( testClass );
}
@Override
protected T createTest()
throws Exception
{
@SuppressWarnings( "unchecked" )
final T instance = (T) super.createTest();
prepareInstance( instance );
return instance;
}
protected void prepareInstance( T instance )
throws Exception
{
}
}