程序包 cn.taketoday.test.context.support
@NonNullApi
@NonNullFields
package cn.taketoday.test.context.support
Support classes for the TestContext Framework.
-
类说明Abstract application context loader that provides a basis for all concrete implementations of the
ContextLoaderSPI.AbstractDelegatingSmartContextLoaderserves as an abstract base class for implementations of theSmartContextLoaderSPI that delegate to a set of candidate SmartContextLoaders (i.e., one that supports XML configuration files or Groovy scripts and one that supports annotated classes) to determine which context loader is appropriate for a given test class's configuration.Abstract base class forTestExecutionListenerimplementations that provide support for marking theApplicationContextassociated with a test as dirty for both test classes and test methods annotated with the@DirtiesContextannotation.Abstract, generic extension ofAbstractContextLoaderthat loads aGenericApplicationContext.Abstract implementation of theTestContextBootstrapperinterface which provides most of the behavior required by a bootstrapper.Abstract ordered implementation of theTestExecutionListenerAPI.Utility methods for working with@ActiveProfilesandActiveProfilesResolvers.Concrete implementation ofAbstractGenericContextLoaderthat loads bean definitions from component classes.Utility methods forSmartContextLoadersthat deal with component classes (e.g.,@Configurationclasses).Utility methods for working withApplicationContextInitializers.@ContextCustomizerFactoriesdefines class-level metadata for configuring whichContextCustomizerFactoryimplementations should be registered with the Infra TestContext Framework.Enumeration of modes that dictate whether explicitly declared factories are merged with the default factories when@ContextCustomizerFactoriesis declared on a class that does not inherit factories from a superclass or enclosing class.Utility methods for resolvingContextConfigurationAttributesfrom the@ContextConfigurationand@ContextHierarchyannotations for use withSmartContextLoaders.Default implementation of theActiveProfilesResolverstrategy that resolves active bean definition profiles based solely on profiles configured declaratively viaActiveProfiles.profiles()orActiveProfiles.value().Default implementation of theBootstrapContextinterface.Default implementation of theTestContextinterface.Default implementation of theTestContextBootstrapperSPI.DelegatingSmartContextLoaderis a concrete implementation ofAbstractDelegatingSmartContextLoaderthat delegates to aGenericXmlContextLoaderAnnotationConfigContextLoader.TestExecutionListenerwhich provides support for dependency injection and initialization of test instances.TestExecutionListenerwhich provides support for marking theApplicationContextassociated with a test as dirty for both test classes and test methods annotated with the@DirtiesContextannotation.TestExecutionListenerwhich provides support for marking theApplicationContextassociated with a test as dirty for both test classes and test methods annotated with the@DirtiesContextannotation.ContextCustomizerto support@DynamicPropertySourcemethods.ContextCustomizerFactoryto support@DynamicPropertySourcemethods.EnumerablePropertySourcebacked by a map with dynamically supplied values.Concrete implementation ofAbstractGenericContextLoaderthat reads bean definitions from JavaPropertiesresources.Concrete implementation ofAbstractGenericContextLoaderthat reads bean definitions from XML resources.MergedTestPropertySourcesencapsulates the merged property sources declared on a test class and all of its superclasses via@TestPropertySource.Strategy for providing named properties — for example, for looking up key-value pairs in a generic fashion.Utility methods for working with@TestConstructor.TestPropertySourceAttributesencapsulates attributes declared via@TestPropertySourceannotations.Utility methods for working with@TestPropertySourceand adding testPropertySourcesto theEnvironment.Extension ofPropertiesthat mimics aSequencedMapby tracking all added properties with aStringkey in aLinkedHashMap.