-
New Feature
-
Resolution: Done
-
Critical
JenkinsRule-based tests generally load not only Jenkins core but also all plugins from ${java.class.path}, i.e., the Maven test-scoped classpath. This is convenient in some ways but also means that class loading is done in a very different way than in an actual production instance, or even mvn hpi:run, making it very hard to test changes like JENKINS-26192 without using the much clunkier, slower, and flakier acceptance-test-harness. It also means that we are forever fighting with Maven's weird transitive dependency management (JENKINS-41631, JENKINS-39301, etc.).
There should be an option to run JenkinsRule in a mode whereby the test classpath is only used to load Jetty; Jenkins core and its WEB-INF/lib/*.jar (including modules!) is loaded in a derivative class loader; and then plugins are discovered from the test classpath, transitive dependencies computed and verified, and finally loaded in the real plugin class loader (probably using *.jpl files to allow us to still load from unpacked development trees). Finally, the test suite itself needs to be reloaded in a fresh loader parented to UberClassLoader, and executed from there.
NbModuleSuite demonstrates the concept, though the details would be rather different for Jenkins.
There are a lot of details to be checked, such as
- @TestExtension handling
- PluginWorkspaceMap support for coördinated snapshot development
- moving InjectedTest from HudsonTestCase so that it can use the new mode
- blocks
-
JENKINS-5303 Upgrade Acegi Security to the latest Spring Security release
- Resolved
- causes
-
JENKINS-62776 NoClassDefFoundErrors after updating
- Resolved
- is blocking
-
JENKINS-50520 Remove jClouds shading
- Resolved
- relates to
-
JENKINS-59442 NoClassDefFoundError of application classes during test
- Resolved
-
JENKINS-31068 The reverse proxy monitor doesn't verify anymore if org.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true on Tomcat
- Resolved
-
JENKINS-48357 Binary Compatibility between JIRA Plugin and Apache HttpComponents Client 4.x API
- Closed
-
JENKINS-46754 2.73+ SSH agent sometimes will not start if using passphrase-protected ed25519 key
- Closed
-
JENKINS-19508 Replace @Extension(optional=true) and optional dependencies with bridge plugins
- Open
-
JENKINS-41631 Use requireUpperBoundDeps in plugin POM
- Resolved
-
JENKINS-39301 During test executions optional transitive plugin dependencies don't get correctly loaded
- Resolved
-
JENKINS-26579 j:getStatic/invokeStatic does not work on plugin classes
- Open
-
JENKINS-60295 jenkins-test-harness does not handle detached plugins properly
- Open
-
JENKINS-61007 pipeline-model-definition is using findbugs without providing / depending on it
- Resolved
-
JENKINS-51779 Use of beta Guava method since deleted: Iterators.skip
- Resolved
-
JENKINS-47118 Extend InjectedTest to include test runs with all optional plugins disabled
- Open
-
JENKINS-30685 Hide core dependencies in plugin classpath
- Open
- links to