Package org.dbunit.annotation.runtime
package org.dbunit.annotation.runtime
-
ClassesClassDescriptionImmutable configuration resolved from one test element's
org.dbunit.annotationinstances, ready forAnnotatedTestExecutorto drive - no dataset has been applied to a database yet, but every dataset path is normalized, every provider and catalog has been consulted, and every reflective instantiation that can fail (a provider or comparer with no accessible no-arg constructor, conflicting inline-value-and-provider attributes) has already happened.Drives one test's dbUnit lifecycle from a resolvedAnnotatedTestConfiguration, dispatchingAnnotatedTestExecutor.beforeTest()/AnnotatedTestExecutor.afterTest(boolean)to one of two path objects -SetupTeardownLifecyclewhenAnnotatedTestConfiguration.isExpected()is false,ExpectedLifecyclewhen it is true - and owning what both share: the oneTestScopedConnectionthis test's steps reuse, itsConnectionOwnershipdecision, the@DbUnitPropertyapplication, and (for an annotation-driven test) theExecutorOperationListenerinstalled on the tester.Normalizes a dataset path fromorg.dbunit.annotation'sDbUnitPreporDbUnitExpectedannotations into an absolute classpath resource path, the formDataFileLoader.load(String)expects.Checks whether a type provides its own body for a method it would otherwise inherit - either an interface default method (DefaultMethodOverrideCheck.overridesDefaultMethod(java.lang.Class<?>, java.lang.Class<?>, java.lang.String, java.lang.Class<?>...)), or a method a known base class declares (DefaultMethodOverrideCheck.declaresBelow(java.lang.Class<?>, java.lang.Class<?>, java.lang.String, java.lang.Class<?>...)).Resolves theIDatabaseTesterfor an already-injected@DbUnitTestCaseinstance:PrepAndExpectedTestCase.getDatabaseTester()if it already has one, otherwise a caller-supplied fallback, wired back onto the test case and round-trip-verified.The shared rules, and the one message shape, for anorg.dbunit.annotationattribute that can be given inline or through a provider class.Reflectively instantiates, via its no-arg constructor, a class anorg.dbunit.annotationattribute names byClass- shared by every such attribute (DbUnitConfig.dataFileLoader(),failureHandler(), aVerifyTableDefinitionsProvidercatalog class, aDatabaseTesterFactory, and so on) so a missing or throwing constructor is reported consistently everywhere.An immutable snapshot of the three pieces of anIDatabaseTesterthe annotation runtime mutates for a test - its dataset, setup operation, and teardown operation - so they can be put back after the test.Reads one or more catalog classes named byDbUnitConfig.verifyDefinitions()orDbUnitExpected.verifyDefinitions()and indexes theirVerifyTableDefinitions by table name, forDbUnitExpected.verifyTables()to select from.