snehashisp commented on code in PR #18403:
URL: https://github.com/apache/kafka/pull/18403#discussion_r1907895838
##########
connect/runtime/src/test/java/org/apache/kafka/connect/runtime/isolation/PluginScannerTest.java:
##########
@@ -137,6 +139,17 @@ public void testVersionedPluginsHasVersion(PluginScanner
scanner) {
versionedPluginResult.forEach(pluginDesc -> assertEquals("1.0.0",
pluginDesc.version()));
}
+ @ParameterizedTest
+ @MethodSource("parameters")
+ public void testClasspathPluginIsAlsoLoadedInIsolation(PluginScanner
scanner) {
+ // json converter is part of the classpath by default
+ String jsonConverterLocation =
JsonConverter.class.getProtectionDomain().getCodeSource().getLocation().getPath();
Review Comment:
Updated the test using a TestPlugin. Setting up a test plugin the way we do
in `assertClassLoaderReadsVersionFromResource` was not working to catch this
regression. I think its because classgraph with addClassLoader sets up its own
classloader chain and not the one we use.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]