Update unit test docs section about @WithPlugin annotation

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

      Unit test documentation at https://wiki.jenkins-ci.org/display/JENKINS/Unit+Test says:

      ----------------------------
      @WithPlugin(NameOfPlugin)
      Installs the specified plugin before launching Jenkins in the test. For now, this has to be one of the plugins statically available in resources "/plugins/NAME".
      ----------------------------

      It's not clear where the plugin has to be put, what should be the plugin file naming convention, and what should be put into NameOfPlugin parameter.

      I suggest the following instead:

      ----------------------------
      @WithPlugin(NameOfPluginFile)
      Installs the specified plugin before launching Jenkins in the test. For now, this has to be one of the plugins statically available in resources "/plugins/NameOfPluginFile". Plugin should be packed as JPI or HPI.

      Example: to install the plugin "my-plugin" before test, put my-plugin.hpi into plugins resource folder (e.g., src/test/plugins/my-plugin.hpi) and add annotation @WithPlugin("my-plugin.hpi") to your test.
      ----------------------------

            Assignee:
            Unassigned
            Reporter:
            Kirill Shepitko
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Archived: