Hi there,
I'm using the JenkinsRule in the test phase of a particular plugin
development and I would like to know how I can install a particular plugin
in the UT phase. For instance:
pom.xml
...
<dependencies>
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>gradle</artifactId>
<version>1.24</version>
<scope>test</scope>
</dependency>
...
// functional code
>
> if (Jenkins.getInstance().pluginManager.getPlugin("gradle") != null) {
> LOG.log(Level.FINE, "Gradlew is installed");
> } else {
> LOG.log(Level.FINE, "Gradlew is NOT installed");
> }
>
> // UI
>
> @Test public void testJobWithGradlew() throws Exception {
> FreeStyleProject project =
> j.createFreeStyleProject("WithWrapper");
> project.getBuildersList().add(new
> hudson.plugins.gradle.Gradle("description","switches","tasks","rootBuildScriptDir","buildFile","gradleName",
>
> true, false, false, false));
> assertFalse(checker.executeCheck(project));
> }
>
>
>
For some reason the gradle plugin is not installed when I run mvn test,
actually it's not installed and I don't see those traces when I run the
testJobWithGradlew test. How can I force that plugin to be installed in the
Test Instance?
Thanks
--
You received this message because you are subscribed to the Google Groups
"Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-dev/c23a32b2-4c42-4dce-a30d-a14a9fbc3c8b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.