runWith (#2691)
This commit is contained in:
committed by
Grzegorz Piwowarek
parent
8a77746e4d
commit
eaba521fdf
@@ -0,0 +1,18 @@
|
||||
package com.baeldung.junit;
|
||||
|
||||
import org.junit.runners.BlockJUnit4ClassRunner;
|
||||
import org.junit.runners.model.FrameworkMethod;
|
||||
import org.junit.runners.model.InitializationError;
|
||||
import org.junit.runners.model.Statement;
|
||||
|
||||
public class BlockingTestRunner extends BlockJUnit4ClassRunner {
|
||||
public BlockingTestRunner(Class<?> klass) throws InitializationError {
|
||||
super(klass);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Statement methodInvoker(FrameworkMethod method, Object test) {
|
||||
System.out.println("invoking: " + method.getName());
|
||||
return super.methodInvoker(method, test);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user