Skip to content

Various code improvements#487

Merged
Abijeet merged 5 commits intomasterfrom
fix-phpunit
Mar 26, 2026
Merged

Various code improvements#487
Abijeet merged 5 commits intomasterfrom
fix-phpunit

Conversation

@Abijeet
Copy link
Copy Markdown
Member

@Abijeet Abijeet commented Mar 24, 2026

Fixes #466
Fixes #467
Fixes #468
Fixes #469

Please review each commit at a time.

Merge strategy: Rebase and merge

Bug: https://phabricator.wikimedia.org/T411267

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the project’s dev test tooling to PHPUnit 10.x in order to address reported security concerns (per T411267).

Changes:

  • Bump phpunit/phpunit dev requirement from 9.6.34 to ^10.1.
  • Regenerate composer.lock to reflect the PHPUnit 10 dependency graph (phpunit/* and sebastian/* package updates/removals).

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated 1 comment.

File Description
composer.json Updates the PHPUnit version constraint to allow PHPUnit 10.x.
composer.lock Locks updated PHPUnit 10.x and related dependency versions, removing now-unneeded packages.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@jdforrester
Copy link
Copy Markdown
Member

9.6.34 is already safe from CVE-2026-24765. As Co-pilot says, if you're upgrading to PHPUnit 10.x (as we should!) is moderately more involved. For MW it's very complicated (see T328919), but updating the PHPUnit config in phpunit.xml is best done in this PR.

@jdforrester
Copy link
Copy Markdown
Member

I think this is now a worse commit? We've gone from fixed, known version of PHPUnit to a floating one.

@Abijeet Abijeet marked this pull request as draft March 24, 2026 15:37
@Abijeet
Copy link
Copy Markdown
Member Author

Abijeet commented Mar 24, 2026

I think this is now a worse commit? We've gone from fixed, known version of PHPUnit to a floating one.

I'll just update to PHPUnit 10.

@Abijeet Abijeet changed the title Update PHPUnit to 10.x to address security issues Update PHPUnit to 10.5.x Mar 25, 2026
@Abijeet Abijeet self-assigned this Mar 25, 2026
@Abijeet Abijeet marked this pull request as ready for review March 25, 2026 01:01
@Abijeet Abijeet requested review from Copilot and jdforrester March 25, 2026 01:01
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 3 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Abijeet Abijeet changed the title Update PHPUnit to 10.5.x Various PHP code improvements Mar 25, 2026
@Abijeet Abijeet changed the title Various PHP code improvements Various code improvements Mar 25, 2026
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 3 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 3 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

This runs all the necessary checks and tests.
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 4 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown
Member

@hueitan hueitan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looking good.

@Abijeet Abijeet merged commit da84799 into master Mar 26, 2026
20 checks passed
Abijeet added a commit that referenced this pull request Mar 26, 2026
@Abijeet Abijeet deleted the fix-phpunit branch March 26, 2026 11:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

4 participants