| java.lang.Object | |||||||||
| ↳ | junit.framework.Assert | ||||||||
| ↳ | junit.framework.TestCase | ||||||||
| ↳ | org.springframework.test.ConditionalTestCase | ||||||||
| ↳ | org.springframework.test.AbstractSpringContextTests | ||||||||
| ↳ | org.springframework.test.AbstractSingleSpringContextTests | ||||||||
| ↳ | org.springframework.test.AbstractDependencyInjectionSpringContextTests | ||||||||
| ↳ | org.springframework.test.AbstractTransactionalSpringContextTests | ||||||||
| ↳ | org.springframework.test.AbstractTransactionalDataSourceSpringContextTests | ||||||||
| ↳ | org.springframework.test.annotation.AbstractAnnotationAwareTransactionalTests | ||||||||
Known Direct Subclasses
|
Known Indirect Subclasses
|
This class is deprecated.
as of Spring 3.0, in favor of using the listener-based test context framework
(AbstractJUnit38SpringContextTests)
Java 5 specific subclass of
AbstractTransactionalDataSourceSpringContextTests, exposing a
SimpleJdbcTemplate and obeying annotations for transaction control.
For example, test methods can be annotated with the regular Spring
@Transactional
annotation (e.g., to force execution in a read-only transaction) or with the
@NotTransactional annotation to prevent any
transaction being created at all. In addition, individual test methods can be
annotated with @Rollback to override the
default rollback settings.
The following list constitutes all annotations currently supported by AbstractAnnotationAwareTransactionalTests:
|
[Expand]
Inherited Constants | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.springframework.test.AbstractDependencyInjectionSpringContextTests
| |||||||||||
| Fields | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| profileValueSource | ProfileValueSource available to subclasses but primarily intended
for use in isDisabledInThisEnvironment(Method). |
||||||||||
| simpleJdbcTemplate | |||||||||||
|
[Expand]
Inherited Fields | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.springframework.test.AbstractTransactionalDataSourceSpringContextTests
| |||||||||||
From class
org.springframework.test.AbstractTransactionalSpringContextTests
| |||||||||||
From class
org.springframework.test.AbstractSingleSpringContextTests
| |||||||||||
From class
org.springframework.test.ConditionalTestCase
| |||||||||||
| Public Constructors | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Default constructor for AbstractAnnotationAwareTransactionalTests, which
delegates to
AbstractAnnotationAwareTransactionalTests(String). | |||||||||||
Constructs a new AbstractAnnotationAwareTransactionalTests instance with
the specified JUnit
name and retrieves the configured (or
default) ProfileValueSource. | |||||||||||
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Overridden to populate transaction definition from annotations.
| |||||||||||
Setter: DataSource is provided by Dependency Injection.
| |||||||||||
| Protected Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
This method is deprecated.
Use
@ProfileValueSourceConfiguration instead.
| |||||||||||
Get the current test method.
| |||||||||||
Determine if the test for the supplied
testMethod should
run in the current environment. | |||||||||||
Determine whether or not to rollback transactions for the current test
by taking into consideration the
default rollback flag and a possible
method-level override via the @Rollback annotation. | |||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.springframework.test.AbstractTransactionalDataSourceSpringContextTests
| |||||||||||
From class
org.springframework.test.AbstractTransactionalSpringContextTests
| |||||||||||
From class
org.springframework.test.AbstractDependencyInjectionSpringContextTests
| |||||||||||
From class
org.springframework.test.AbstractSingleSpringContextTests
| |||||||||||
From class
org.springframework.test.AbstractSpringContextTests
| |||||||||||
From class
org.springframework.test.ConditionalTestCase
| |||||||||||
From class
junit.framework.TestCase
| |||||||||||
From class
junit.framework.Assert
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface
junit.framework.Test
| |||||||||||
ProfileValueSource available to subclasses but primarily intended
for use in isDisabledInThisEnvironment(Method).
Set to SystemProfileValueSource by default for backwards
compatibility; however, the value may be changed in the
AbstractAnnotationAwareTransactionalTests(String) constructor.
Default constructor for AbstractAnnotationAwareTransactionalTests, which
delegates to AbstractAnnotationAwareTransactionalTests(String).
Constructs a new AbstractAnnotationAwareTransactionalTests instance with
the specified JUnit name and retrieves the configured (or
default) ProfileValueSource.
| name | the name of the current test |
|---|
Overridden to populate transaction definition from annotations.
| Throwable |
|---|
Setter: DataSource is provided by Dependency Injection.
This method is deprecated.
Use @ProfileValueSourceConfiguration instead.
Search for a unique ProfileValueSource in the supplied
ApplicationContext. If found, the
profileValueSource for this test will be set to the unique
ProfileValueSource.
| applicationContext | the ApplicationContext in which to search for
the ProfileValueSource; may not be null |
|---|
Determine if the test for the supplied testMethod should
run in the current environment.
The default implementation is based on
@IfProfileValue semantics.
| testMethod | the test method |
|---|
true if the test is disabled in the current environmentDetermine whether or not to rollback transactions for the current test
by taking into consideration the
default rollback flag and a possible
method-level override via the @Rollback annotation.