Polish TransactionalTestExecutionListener
This commit is contained in:
@@ -30,6 +30,7 @@ import org.springframework.beans.BeansException;
|
||||
import org.springframework.beans.factory.BeanFactory;
|
||||
import org.springframework.beans.factory.annotation.BeanFactoryAnnotationUtils;
|
||||
import org.springframework.core.annotation.AnnotatedElementUtils;
|
||||
import org.springframework.test.annotation.Commit;
|
||||
import org.springframework.test.annotation.Rollback;
|
||||
import org.springframework.test.context.TestContext;
|
||||
import org.springframework.test.context.support.AbstractTestExecutionListener;
|
||||
@@ -43,7 +44,8 @@ import org.springframework.util.Assert;
|
||||
import org.springframework.util.ReflectionUtils;
|
||||
import org.springframework.util.StringUtils;
|
||||
|
||||
import static org.springframework.core.annotation.AnnotationUtils.*;
|
||||
import static org.springframework.core.annotation.AnnotationUtils.findAnnotation;
|
||||
import static org.springframework.core.annotation.AnnotationUtils.getAnnotation;
|
||||
|
||||
/**
|
||||
* {@code TestExecutionListener} that provides support for executing tests
|
||||
@@ -83,8 +85,9 @@ import static org.springframework.core.annotation.AnnotationUtils.*;
|
||||
* <h3>Declarative Rollback and Commit Behavior</h3>
|
||||
* <p>By default, test transactions will be automatically <em>rolled back</em>
|
||||
* after completion of the test; however, transactional commit and rollback
|
||||
* behavior can be configured declaratively via the {@link Rollback @Rollback}
|
||||
* annotation at the class level and at the method level.
|
||||
* behavior can be configured declaratively via the {@link Commit @Commit}
|
||||
* and {@link Rollback @Rollback} annotations at the class level and at the
|
||||
* method level.
|
||||
*
|
||||
* <h3>Programmatic Transaction Management</h3>
|
||||
* <p>As of Spring Framework 4.1, it is possible to interact with test-managed
|
||||
|
||||
Reference in New Issue
Block a user