Package io.awspring.cloud.test.sqs
Annotation Interface SqsTest
@Target(TYPE)
@Retention(RUNTIME)
@Documented
@Inherited
@BootstrapWith(SqsTestContextBootstrapper.class)
@OverrideAutoConfiguration(enabled=false)
@TypeExcludeFilters(SqsTypeExcludeFilter.class)
@ExtendWith(org.springframework.test.context.junit.jupiter.SpringExtension.class)
@AutoConfigureSqs
@ImportAutoConfiguration
public @interface SqsTest
Annotation for a SQS test that focuses only on SQS-based components.
Using this annotation will disable full auto-configuration and instead apply only configuration relevant to SQS tests.
When using JUnit 4, this annotation should be used in combination with @RunWith(SpringRunner.class)
.
- Since:
- 2.4.0
- Author:
- Maciej Walkowiak
- See Also:
-
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionA set of exclude filters which can be used to filter beans that would otherwise be added to the application context.A set of include filters which can be used to add otherwise filtered beans to the application context.Class<?>[]
Specifies the listeners to test.String[]
Properties in form key=value that should be added to the SpringEnvironment
before the test runs.boolean
Determines if default filtering should be used with@SpringBootApplication
.Class<?>[]
Specifies the listeners to test.
-
Element Details
-
useDefaultFilters
boolean useDefaultFiltersDetermines if default filtering should be used with@SpringBootApplication
. By default no beans are included.- Returns:
- if default filters should be used
- See Also:
- Default:
- true
-
value
Specifies the listeners to test. This is an alias oflisteners()
which can be used for brevity if no other attributes are defined. Seelisteners()
for details.- Returns:
- the listeners to test
- See Also:
- Default:
- {}
-
listeners
Specifies the listeners to test.- Returns:
- the listeners to test
- See Also:
- Default:
- {}
-
properties
String[] propertiesProperties in form key=value that should be added to the SpringEnvironment
before the test runs.- Returns:
- the properties to add
- Default:
- {}
-
includeFilters
ComponentScan.Filter[] includeFiltersA set of include filters which can be used to add otherwise filtered beans to the application context.- Returns:
- include filters to apply
- Default:
- {}
-
excludeFilters
ComponentScan.Filter[] excludeFiltersA set of exclude filters which can be used to filter beans that would otherwise be added to the application context.- Returns:
- exclude filters to apply
- Default:
- {}
-