[JENKINS-46257] Improve Run Parameters folders support for auto-completion#26339
[JENKINS-46257] Improve Run Parameters folders support for auto-completion#26339Flamki wants to merge 1 commit intojenkinsci:masterfrom
Conversation
|
CI failure appears unrelated to this PR.\n\nAll failing jobs report SetupWizardTest.testRemoteUpdateSitePerformingValidation, which is currently tracked as a master issue in #26341 (expired test certificate).\n\nThis PR only changes RunParameter autocomplete context and adds a focused regression test. I will rebase/rerun once the upstream fix for #26341 is merged. |
|
CI failure appears unrelated to this PR. All failing jobs report I will rebase and rerun once the upstream fix for #26341 is merged. |
That is correct. The failure is due to an expired certificate in the test. The issue is tracked as: |
762dabd to
3c02f08
Compare
3c02f08 to
4bf2987
Compare
|
Rebased this PR on latest This PR remains the same functional change:
Ready for review once checks complete. Thanks. |
Please don't rebase. It causes problems for reviewers. A series of commits will be squash merged and are easier for reviewers to understand the association between changes and review comments. |
There was a problem hiding this comment.
Pull request overview
This PR improves Run Parameter project name auto-completion so it uses the local folder context, enabling sibling job resolution when jobs are organized in folders (addressing JENKINS-46257 / #22250).
Changes:
- Update
RunParameterDefinition.DescriptorImpl#doAutoCompleteProjectNameto accept@AncestorInPathcontext (Item self,ItemGroup container) and use context-awareAutoCompletionCandidates.ofJobNames. - Add a regression test covering auto-completion behavior for sibling jobs inside a folder.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
core/src/main/java/hudson/model/RunParameterDefinition.java |
Passes Stapler ancestor context into job-name auto-completion to support folder-local resolution. |
test/src/test/java/hudson/model/RunParameterDefinitionTest.java |
Adds a regression test ensuring folder-local auto-completion returns sibling job names. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Fixes #22250
Testing done
autoCompleteProjectNameInFoldersUsesLocalContextinRunParameterDefinitionTest.mvnis not installed (CommandNotFoundException); CI is expected to run full validation.Screenshots (UI changes only)
Before
N/A
After
N/A
Proposed changelog entries
Proposed changelog category
/label rfe
Proposed upgrade guidelines
N/A
Submitter checklist
@Restrictedor have@since TODOJavadocs, as appropriate. (No new public API in this PR.)@Deprecated(since = "TODO")or@Deprecated(forRemoval = true, since = "TODO"), if applicable. (No new deprecations in this PR.)evalto ease future introduction of Content Security Policy (CSP) directives (see documentation). (No JS/UI behavior change in this PR.)Desired reviewers
@jenkinsci/core-pr-reviewers
Before the changes are marked as
ready-for-merge:Maintainer checklist
upgrade-guide-neededlabel is set and there is a Proposed upgrade guidelines section in the pull request title (see example).lts-candidateto be considered.