Package io.quarkus.test.junit
Class TestResourceUtil.TestResourceManagerReflections
java.lang.Object
io.quarkus.test.junit.TestResourceUtil.TestResourceManagerReflections
- Enclosing class:
TestResourceUtil
Contains a bunch of utilities that are needed for handling
TestResourceManager
via reflection (due to different classloaders)-
Method Summary
Modifier and TypeMethodDescriptionstatic <T> List<T> copyEntriesFromProfile(QuarkusTestProfile profileInstance, ClassLoader classLoader) SinceTestResourceManageris loaded from the ClassLoader passed in as an argument, we need to convert the user inputQuarkusTestProfile.TestResourceEntryinto instances ofTestResourceManager.TestResourceClassEntrythat are loaded from that ClassLoaderstatic CloseablecreateReflectively(Class<?> testResourceManagerClass, Class<?> testClass, Class<?> profileClass, List<TestResourceManager.TestResourceClassEntry> additionalTestResources, boolean disableGlobalTestResources, Map<String, String> devServicesProperties, Optional<String> containerNetworkId) static CloseablecreateReflectively(Class<?> testResourceManagerClass, Class<?> testClass, Class<?> profileClass, List<TestResourceManager.TestResourceClassEntry> additionalTestResources, boolean disableGlobalTestResources, Map<String, String> devServicesProperties, Optional<String> containerNetworkId, Path testClassLocation) static voidinitReflectively(Object testResourceManager, Class<?> profileClassName) Corresponds toTestResourceManager.init(String)startReflectively(Object testResourceManager) Corresponds toTestResourceManager.start()(package private) static Set<TestResourceManager.TestResourceComparisonInfo> testResourceComparisonInfo(Object testResourceManager) Corresponds toTestResourceManager.testResourceComparisonInfo()
-
Method Details
-
copyEntriesFromProfile
public static <T> List<T> copyEntriesFromProfile(QuarkusTestProfile profileInstance, ClassLoader classLoader) SinceTestResourceManageris loaded from the ClassLoader passed in as an argument, we need to convert the user inputQuarkusTestProfile.TestResourceEntryinto instances ofTestResourceManager.TestResourceClassEntrythat are loaded from that ClassLoader -
createReflectively
public static Closeable createReflectively(Class<?> testResourceManagerClass, Class<?> testClass, Class<?> profileClass, List<TestResourceManager.TestResourceClassEntry> additionalTestResources, boolean disableGlobalTestResources, Map<String, String> devServicesProperties, Optional<String> containerNetworkId, Path testClassLocation) -
createReflectively
public static Closeable createReflectively(Class<?> testResourceManagerClass, Class<?> testClass, Class<?> profileClass, List<TestResourceManager.TestResourceClassEntry> additionalTestResources, boolean disableGlobalTestResources, Map<String, String> devServicesProperties, Optional<String> containerNetworkId) -
initReflectively
Corresponds toTestResourceManager.init(String) -
startReflectively
Corresponds toTestResourceManager.start() -
testResourceComparisonInfo
static Set<TestResourceManager.TestResourceComparisonInfo> testResourceComparisonInfo(Object testResourceManager) Corresponds toTestResourceManager.testResourceComparisonInfo()
-