Package org.jvnet.hudson.test.recipes
Annotation Interface WithPlugin
@Documented
@Recipe(RunnerImpl.class)
@JenkinsRecipe(RuleRunnerImpl.class)
@Target(METHOD)
@Retention(RUNTIME)
public @interface WithPlugin
Installs the specified plugins before launching Jenkins.
- Author:
- Kohsuke Kawaguchi
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic class -
Required Element Summary
Required Elements
-
Element Details
-
value
String[] valueFilenames of the plugins to install. These are expected to be of the formworkflow-job.jpiwhere/plugins/workflow-job.jpiis a test classpath resource. (The basename should be a plugin short name and the extension should bejpi.)Committing that file to SCM (say,
src/test/resources/plugins/sample.jpi) is reasonable for small fake plugins built for this purpose and exercising some bit of code. If you wish to test with larger archives of real plugins, this is possible for example by bindingdependency:copyto theprocess-test-resourcesphase.In most cases you do not need this annotation. Simply add whatever plugins you are interested in testing against to your POM in
testscope. These, and their transitive dependencies, will be loaded in allJenkinsRuletests in this plugin. This annotation is useful if only a particular test may load the tested plugin, or if the tested plugin is not available in a repository for use as a test dependency.
-