Skip to content

Commit

Permalink
Unpin plugin versions
Browse files Browse the repository at this point in the history
  • Loading branch information
basil committed Aug 26, 2024
1 parent 1f099f3 commit 867a281
Show file tree
Hide file tree
Showing 17 changed files with 34 additions and 34 deletions.
2 changes: 1 addition & 1 deletion src/test/java/core/CredentialsTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
/**
* @author Vivek Pandey
*/
@WithPlugins("credentials@2.0.7")
@WithPlugins("credentials")
public class CredentialsTest extends AbstractJUnitTest {
private static final String GLOBAL_SCOPE = "GLOBAL";
private static final String SYSTEM_SCOPE = "SYSTEM";
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/ActiveDirectoryTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
*
* @author [email protected]
*/
@WithPlugins("active-directory@1.38")
@WithPlugins("active-directory")
public class ActiveDirectoryTest extends AbstractJUnitTest {
// This should ideally use @TestActivation but it requires nonstandard properties so failing assumption in instance initialization instead.
private final ActiveDirectoryEnv ENV = ActiveDirectoryEnv.get();
Expand Down
16 changes: 8 additions & 8 deletions src/test/java/plugins/CredentialsBindingTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
import org.junit.Test;
import org.openqa.selenium.WebDriver;

@WithPlugins ({"credentials@2.0.7", "workflow-job", "workflow-cps", "workflow-basic-steps", "workflow-durable-task-step"})
@WithPlugins ({"credentials", "workflow-job", "workflow-cps", "workflow-basic-steps", "workflow-durable-task-step"})
public class CredentialsBindingTest extends AbstractCredentialsTest {

private static final String USERNAME_CORRECT_MESSAGE = "username has the correct value";
Expand Down Expand Up @@ -92,7 +92,7 @@ public void testTextBinding() {
}

@Test
@WithPlugins("credentials-binding@1.10")
@WithPlugins("credentials-binding")
public void pipelineWithCredentialsTest() throws IOException {
CredentialsPage cp = createCredentialsPage(false);
createCredentials(UserPwdCredential.class, cp, GLOBAL_SCOPE, null);
Expand All @@ -103,43 +103,43 @@ public void pipelineWithCredentialsTest() throws IOException {
}

@Test
@WithPlugins({"credentials-binding@1.17", "authorize-project"})
@WithPlugins({"credentials-binding", "authorize-project"})
public void pipelineUsernamePersonalCredentials() throws URISyntaxException, IOException {
final String script = PipelineTestUtils.scriptForPipelineFromResourceWithParameters(this.getClass(), PipelineTestUtils.resolveScriptName("usernameSplitPasswordScript"), CRED_ID, CRED_USER, USERNAME_CORRECT_MESSAGE, CRED_PWD, PASSWORD_CORRECT_MESSAGE);
this.testPersonalCredentials(UserPwdCredential.class, null, script, USERNAME_CORRECT_MESSAGE, PASSWORD_CORRECT_MESSAGE);
}


@Test
@WithPlugins({"credentials-binding@1.17", "authorize-project"})
@WithPlugins({"credentials-binding", "authorize-project"})
public void pipelineUsernameTogetherPersonalCredentials() throws URISyntaxException, IOException {
final String script = PipelineTestUtils.scriptForPipelineFromResourceWithParameters(this.getClass(), PipelineTestUtils.resolveScriptName("usernameTogetherPasswordScript"), CRED_ID, CRED_USER + ":" + CRED_PWD, COMPLETE_PASSWORD_CORRECT_MESSAGE);
this.testPersonalCredentials(UserPwdCredential.class, null, script, COMPLETE_PASSWORD_CORRECT_MESSAGE);
}

@Test
@WithPlugins({"credentials-binding@1.17", "authorize-project"})
@WithPlugins({"credentials-binding", "authorize-project"})
public void pipelineSecretTextPersonalCredentials() throws URISyntaxException, IOException {
final String script = PipelineTestUtils.scriptForPipelineFromResourceWithParameters(this.getClass(), PipelineTestUtils.resolveScriptName("secretTextScript"), CRED_ID, AbstractCredentialsTest.SECRET_TEXT, SECRET_TEXT_CORRECT_MESSAGE);
this.testPersonalCredentials(StringCredentials.class, null, script, SECRET_TEXT_CORRECT_MESSAGE);
}

@Test
@WithPlugins({"credentials-binding@1.17", "authorize-project"})
@WithPlugins({"credentials-binding", "authorize-project"})
public void pipelineSecretFilePersonalCredentials() throws URISyntaxException, IOException {
final String script = PipelineTestUtils.scriptForPipelineFromResourceWithParameters(this.getClass(), PipelineTestUtils.resolveScriptName("secretFileScript"), CRED_ID, SECRET_FILE_TEXT, SECRET_FILE_CORRECT_MESSAGE);
this.testPersonalCredentials(FileCredentials.class, SECRET_FILE, script, SECRET_FILE_CORRECT_MESSAGE);
}

@Test
@WithPlugins({"credentials-binding@1.17", "authorize-project"})
@WithPlugins({"credentials-binding", "authorize-project"})
public void pipelineSecretZipPersonalCredentials() throws URISyntaxException, IOException {
final String script = PipelineTestUtils.scriptForPipelineFromResourceWithParameters(this.getClass(), PipelineTestUtils.resolveScriptName("secretZipFileScript"), CRED_ID, SECRET_ZIP_FILE_TEXT, SECRET_ZIP_FILE_CORRECT_MESSAGE);
this.testPersonalCredentials(FileCredentials.class, SECRET_ZIP_FILE, script, SECRET_ZIP_FILE_CORRECT_MESSAGE);
}

@Test
@WithPlugins({"credentials-binding@1.17", "authorize-project"})
@WithPlugins({"credentials-binding", "authorize-project"})
public void pipelineSSHUserPrivateKeyCredentials() throws URISyntaxException, IOException {
final String script = PipelineTestUtils.scriptForPipelineFromResourceWithParameters(this.getClass(), PipelineTestUtils.resolveScriptName("sshUserPrivateKeyScript"), CRED_ID, CRED_USER, USERNAME_CORRECT_MESSAGE, "", PASSWORD_CORRECT_MESSAGE, CRED_PWD, PRIVATE_KEY_CORRECT_MESSAGE);
this.testPersonalCredentials(SshPrivateKeyCredential.class, null, script, USERNAME_CORRECT_MESSAGE, PASSWORD_CORRECT_MESSAGE, PRIVATE_KEY_CORRECT_MESSAGE);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
import org.junit.Test;
import org.openqa.selenium.By;

@WithPlugins({"declarative-pipeline-migration-assistant@1.0.3","declarative-pipeline-migration-assistant-api@1.0.3"})
@WithPlugins({"declarative-pipeline-migration-assistant","declarative-pipeline-migration-assistant-api"})
public class DeclarativeAssistantMigrationTest
extends AbstractJUnitTest
{
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/DisplayUrlApiTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
*/
@WithDocker
@Category(DockerTest.class)
@WithPlugins({"mailer@1.18", "workflow-job", "workflow-cps", "workflow-basic-steps", "workflow-durable-task-step"})
@WithPlugins({"mailer", "workflow-job", "workflow-cps", "workflow-basic-steps", "workflow-durable-task-step"})
public class DisplayUrlApiTest extends AbstractPipelineTest {

@Inject
Expand Down
14 changes: 7 additions & 7 deletions src/test/java/plugins/JobDslPluginTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public class JobDslPluginTest extends AbstractJUnitTest {
* Verifies that all configurations, done on the job configuration page,
* are saved correctly.
*/
@Test @WithPlugins({"matrix-auth@2.3","mock-security-realm"})
@Test @WithPlugins({"matrix-auth","mock-security-realm"})
public void should_save_configurations() {
FreeStyleJob seedJob = createSeedJob();
JobDslBuildStep jobDsl = seedJob.addBuildStep(JobDslBuildStep.class);
Expand Down Expand Up @@ -518,7 +518,7 @@ public void should_use_additional_classpath() {
* wont be executed, because they are not approved.
* If script security for Job DSL scripts is disabled, the script can be executed.
*/
@Test @WithPlugins({"matrix-auth@2.3","mock-security-realm"})
@Test @WithPlugins({"matrix-auth","mock-security-realm"})
public void should_use_script_security() {
GlobalSecurityConfig sc = setUpSecurity();

Expand Down Expand Up @@ -554,7 +554,7 @@ public void should_use_script_security() {
* security is enabled, it is not possible to import Groovy classes from the
* workspace.
*/
@Test @WithPlugins({"matrix-auth@2.3","mock-security-realm"})
@Test @WithPlugins({"matrix-auth","mock-security-realm"})
public void should_disallow_importing_groovy_classes_when_script_security_enabled() {
GlobalSecurityConfig sc = setUpSecurity();

Expand Down Expand Up @@ -585,7 +585,7 @@ public void should_disallow_importing_groovy_classes_when_script_security_enable
* Administrators can approve scripts in the 'Script Approval' of the
* 'Manage Jenkins' area. Approved scripts can be executed.
*/
@Test @WithPlugins({"matrix-auth@2.3","mock-security-realm"})
@Test @WithPlugins({"matrix-auth","mock-security-realm"})
public void should_use_script_approval() {
setUpSecurity();

Expand Down Expand Up @@ -623,7 +623,7 @@ public void should_use_script_approval() {
* scripts saved by non administrators can run in a Groovy sandbox
* without approval. All Job DSL methods are whitelisted by default.
*/
@Test @WithPlugins({"matrix-auth@2.3","mock-security-realm","authorize-project"})
@Test @WithPlugins({"matrix-auth","mock-security-realm","authorize-project"})
public void should_use_grooy_sandbox_whitelisted_content() {
GlobalSecurityConfig sc = setUpSecurity();
runBuildAsUserWhoTriggered(sc);
Expand Down Expand Up @@ -653,7 +653,7 @@ public void should_use_grooy_sandbox_whitelisted_content() {
* Administrators can approve this content in the 'Script Approval' of the
* 'Manage Jenkins' area. Approved scripts can be executed.
*/
@Test @WithPlugins({"matrix-auth@2.3","mock-security-realm","authorize-project"})
@Test @WithPlugins({"matrix-auth","mock-security-realm","authorize-project"})
public void should_use_grooy_sandbox_no_whitelisted_content() {
GlobalSecurityConfig sc = setUpSecurity();
runBuildAsUserWhoTriggered(sc);
Expand Down Expand Up @@ -692,7 +692,7 @@ public void should_use_grooy_sandbox_no_whitelisted_content() {
* Verifies that Groovy sandbox can only used if 'Access Control for Builds'
* is configured. The DSL job needs to run as a particular user.
*/
@Test @WithPlugins({"matrix-auth@2.3","mock-security-realm","authorize-project"})
@Test @WithPlugins({"matrix-auth","mock-security-realm","authorize-project"})
public void should_run_grooy_sandbox_as_particular_user() {
GlobalSecurityConfig sc = setUpSecurity();

Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/LdapPluginTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
*/
@Category(DockerTest.class)
@WithDocker
@WithPlugins("ldap@1.10")
@WithPlugins("ldap")
public class LdapPluginTest extends AbstractJUnitTest {

@Inject
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/MailWatcherPluginTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public void notify_slave_on_restart() throws Exception {
mailhog.assertMail(regex("Computer %s marked online", slave.getName()), "[email protected]");
}

@Test @Issue("JENKINS-20538") @Since("1.571") @WithPlugins("mail-watcher-plugin@1.7")
@Test @Issue("JENKINS-20538") @Since("1.571") @WithPlugins("mail-watcher-plugin")
@Ignore("Flaky test, passes sometimes on CI")
public void notify_master_on_jenkins_restart() throws Exception {
jenkins.configure();
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/MatrixAuthPluginTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
/**
* @author Kohsuke Kawaguchi
*/
@WithPlugins({"matrix-auth@2.3"})
@WithPlugins({"matrix-auth"})
public class MatrixAuthPluginTest extends AbstractJUnitTest {
/**
* Test scenario:
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/PlainCredentialsBindingTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
/**
* Tests the plain-credentials and credentials-binding plugins together.
*/
@WithPlugins({"plain-credentials", "credentials-binding", "credentials@2.0"})
@WithPlugins({"plain-credentials", "credentials-binding", "credentials"})
public class PlainCredentialsBindingTest extends AbstractCredentialsTest {

private static final String BINDING_VARIABLE = "BINDING_VARIABLE";
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/SSHCredentialsTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
import org.junit.Test;
import org.openqa.selenium.By;

@WithPlugins({"ssh-credentials", "credentials@2.1.5"})
@WithPlugins({"ssh-credentials", "credentials"})
public class SSHCredentialsTest extends AbstractCredentialsTest {

private static final String CHECK_PERSONAL_CREDENTIAL_STRING = "println(com.cloudbees.plugins.credentials.CredentialsProvider.lookupCredentials(com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey.class, Jenkins.instance, hudson.model.User.current().impersonate(), null).find {it.id == \"%s\" }.privateKey);";
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/SshSlavesPluginTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
import org.jvnet.hudson.test.Issue;
import org.openqa.selenium.NoSuchElementException;

@WithPlugins({"ssh-slaves@1.11", "credentials@2.1.10", "ssh-credentials@1.12"})
@WithPlugins({"ssh-slaves", "credentials", "ssh-credentials"})
@Category(DockerTest.class)
@WithDocker
public class SshSlavesPluginTest extends AbstractJUnitTest {
Expand Down
4 changes: 2 additions & 2 deletions src/test/java/plugins/StageViewTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public void jobShouldContainStageView() {
* aka Pagination
*/
@Test
@WithPlugins("pipeline-stage-view@2.18")
@WithPlugins("pipeline-stage-view")
public void multiBuildJobShouldContainCorrectNumberOfJobsBuilt() {
WorkflowJob job = this.createPipelineFromFile(SINGLE_JOB);
Build build = null;
Expand All @@ -73,7 +73,7 @@ public void multiBuildJobShouldContainCorrectNumberOfJobsBuilt() {
* to new stages with future builds.
*/
@Test
@WithPlugins("pipeline-stage-view@2.18")
@WithPlugins("pipeline-stage-view")
public void multiBuildJobShouldContainCorrectNumberOfJobsHeadline() {
WorkflowJob job = jenkins.jobs.create(WorkflowJob.class);
String pre = "node {\n";
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/SubversionPluginTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
/**
* @author Matthias Karl
*/
@WithPlugins("subversion@2.3")
@WithPlugins("subversion")
@Category(DockerTest.class)
@WithDocker
public class SubversionPluginTest extends AbstractJUnitTest {
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/WorkflowMultibranchTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
/**
* Tests a multibranch pipeline flow
*/
@WithPlugins({"git", "javadoc@1.4", "workflow-basic-steps", "workflow-durable-task-step", "workflow-multibranch", "github-branch-source@2.5.5"})
@WithPlugins({"git", "javadoc", "workflow-basic-steps", "workflow-durable-task-step", "workflow-multibranch", "github-branch-source"})
public class WorkflowMultibranchTest extends AbstractJUnitTest {

@Before
Expand Down
8 changes: 4 additions & 4 deletions src/test/java/plugins/WorkflowPluginTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ private String createGitRepositoryInDockerContainer() throws IOException {
}
}

@WithPlugins({"workflow-job", "workflow-cps@2.10", "workflow-basic-steps@2.1", "workflow-durable-task-step", "pipeline-input-step", "junit@1.18", "git@2.3"})
@WithPlugins({"workflow-job", "workflow-cps", "workflow-basic-steps", "workflow-durable-task-step", "pipeline-input-step", "junit", "git"})
@Test public void linearFlow() throws Exception {
MavenInstallation.installMaven(jenkins, "M3", "3.9.4");
final DumbSlave slave = (DumbSlave) slaveController.install(jenkins).get();
Expand Down Expand Up @@ -162,7 +162,7 @@ private String createGitRepositoryInDockerContainer() throws IOException {
assertThat(driver, hasContent("All Tests"));
}

@WithPlugins({"workflow-job", "workflow-cps@2.10", "workflow-basic-steps@2.1", "workflow-durable-task-step", "parallel-test-executor@1.11", "junit@1.18", "git@2.3"})
@WithPlugins({"workflow-job", "workflow-cps", "workflow-basic-steps", "workflow-durable-task-step", "parallel-test-executor", "junit", "git"})
@Native("mvn")
@Test public void parallelTests() throws Exception {
for (int i = 0; i < 3; i++) {
Expand Down Expand Up @@ -214,7 +214,7 @@ private String createGitRepositoryInDockerContainer() throws IOException {
/** Pipeline analogue of {@link SubversionPluginTest#build_has_changes}. */
@Category(DockerTest.class)
@WithDocker
@WithPlugins({"workflow-cps@2.12", "workflow-job@2.5", "workflow-durable-task-step@2.4", "subversion@2.6"})
@WithPlugins({"workflow-cps", "workflow-job", "workflow-durable-task-step", "subversion"})
@Test public void subversion() throws Exception {
final SvnContainer svnContainer = svn.get();
WorkflowJob job = jenkins.jobs.create(WorkflowJob.class);
Expand All @@ -228,7 +228,7 @@ private String createGitRepositoryInDockerContainer() throws IOException {
assertTrue(b2.getChanges().hasChanges());
}

@WithPlugins({"git@3.0.1", "workflow-job", "workflow-cps", "workflow-basic-steps", "workflow-durable-task-step", "workflow-multibranch", "github-branch-source@2.5.5", "pipeline-groovy-lib"})
@WithPlugins({"git", "workflow-job", "workflow-cps", "workflow-basic-steps", "workflow-durable-task-step", "workflow-multibranch", "github-branch-source", "pipeline-groovy-lib"})
@Test
public void testSharedLibraryFromGithub() {
this.configureSharedLibrary();
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/plugins/XvncPluginTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public void use_specific_display_number() {
assertThat(build, XvncJobConfig.usedDisplayNumber(42));
}

@WithPlugins({"xvnc@1.22", "workflow-aggregator@1.8"})
@WithPlugins({"xvnc", "workflow-aggregator"})
@Issue("JENKINS-26477")
@Test public void workflow() {
WorkflowJob job = jenkins.jobs.create(WorkflowJob.class);
Expand Down

0 comments on commit 867a281

Please sign in to comment.