Lokasi ngalangkungan proxy:   [ UP ]  
[Ngawartoskeun bug]   [Panyetelan cookie]                
Skip to content

test(core): restore CLI state and correct assertion in SetupTest - #62772

Merged
skjnldsv merged 1 commit into
masterfrom
jtr/test-fix-Setup-testFindRootCli-state
Dec 1, 2026
Merged

skjnldsv merged 1 commit into
masterfrom
jtr/test-fix-Setup-testFindRootCli-state

Conversation

@joshtrichards

Copy link
Copy Markdown
Member

🔀 Review triage: ⚠️ Risk: Low · ⏱️ Effort: Quick

Summary

Ensure testFindWebRootCli() restores \OC::$CLI even when an unexpected exception occurs, and correct the PHPUnit assertion argument order.

No production code changes.

Related production code: Setup::findWebRoot()

Testing

Existing testFindWebRootCli() data-provider coverage is unchanged.

Checklist

  • Code is properly formatted
  • Sign-off message is included
  • Tests are included
  • Documentation is not required
  • Backport is not required
  • Labels added
  • Milestone added

AI disclosure

  • The content of this PR was partly or fully generated using AI

@joshtrichards joshtrichards added this to the Nextcloud 35 milestone Aug 2, 2026
@joshtrichards
joshtrichards requested a review from a team as a code owner August 2, 2026 13:49
@joshtrichards
joshtrichards requested review from Altahrim, icewind1991 and salmart-dev and removed request for a team August 2, 2026 13:49
@joshtrichards joshtrichards added the 3. to review Waiting for reviews label Aug 2, 2026
@joshtrichards joshtrichards added feature: install and update tests Related to tests ⚠️ risk: low Unlikely to cause meaningful regressions; limited runtime or compatibility impact. ⏱️ review-effort: quick Can usually be reviewed from the diff and nearby context; targeted validation may be sufficient. labels Aug 2, 2026
This was referenced Aug 12, 2026
@nextcloud-bot nextcloud-bot mentioned this pull request Aug 20, 2026
@skjnldsv skjnldsv mentioned this pull request Aug 25, 2026
testFindWebRootCli() can leak it's temporarily overridden `\OC::$CLI` if an unexpected exception occurs.

Also expected/actual arguments on the assert are reversed.

Signed-off-by: Josh <josh.t.richards@gmail.com>
@skjnldsv
skjnldsv force-pushed the jtr/test-fix-Setup-testFindRootCli-state branch from 617304c to 998d50e Compare December 1, 2026 10:27
@skjnldsv
skjnldsv enabled auto-merge December 1, 2026 10:36
@skjnldsv
skjnldsv merged commit 912006e into master Dec 1, 2026
175 of 186 checks passed
@skjnldsv
skjnldsv deleted the jtr/test-fix-Setup-testFindRootCli-state branch December 1, 2026 18:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review Waiting for reviews feature: install and update ⏱️ review-effort: quick Can usually be reviewed from the diff and nearby context; targeted validation may be sufficient. ⚠️ risk: low Unlikely to cause meaningful regressions; limited runtime or compatibility impact. tests Related to tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants