-
Notifications
You must be signed in to change notification settings - Fork 0
Bumped phpunit to ^12 #36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Resolves #34
|
Warning Rate limit exceeded@MekDrop has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 16 minutes and 12 seconds before requesting another review. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📒 Files selected for processing (1)
WalkthroughThe changes update the PHPUnit development dependency to version 12, revise the PHPUnit configuration to match schema 12.2, and update test annotations to use PHPUnit 12's native attribute syntax. No production code or public API changes are present; all modifications are related to test infrastructure and configuration. Changes
Sequence Diagram(s)sequenceDiagram
participant Developer
participant Composer
participant PHPUnit12
participant TestSuite
Developer->>Composer: composer install / update
Composer->>PHPUnit12: Install PHPUnit v12
Developer->>TestSuite: Run tests (phpunit)
TestSuite->>PHPUnit12: Use native attribute annotations
PHPUnit12-->>TestSuite: Execute tests as configured in phpunit.xml
Assessment against linked issues
Possibly related issues
Poem
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (2)
composer.json (1)
27-29: Loosening the PHP version constraint could avoid unnecessary test-suite blockersPHPUnit 12 only requires PHP ≥ 8.2, while the library currently pins runtime PHP to
^8.3. If 8.3+ is not a hard requirement for the production code, consider relaxing the constraint to^8.2so contributors running 8.2 can still install the dev-dependency and execute the test-suite.- "php": "^8.3", + "php": "^8.2",phpunit.xml (1)
8-12: Add a suffix to the<directory>element to prevent non-PHP files from being scannedWithout the
suffixattribute PHPUnit will parse every file undersrc/, which slows collection and may include stubs, docs, etc. Limiting the scan to*.phpis the common practice.- <directory>src</directory> + <directory suffix=".php">src</directory>
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
composer.json(1 hunks)phpunit.xml(1 hunks)tests/OutputDecoratorTest.php(4 hunks)
🔇 Additional comments (4)
tests/OutputDecoratorTest.php (4)
4-4: Nice upgrade to native attribute syntaxImporting
PHPUnit\Framework\Attributes\DataProvidermodernises the test suite and keeps it forward-compatible with PHPUnit 12. 👍
101-119: Attribute usage looks correct
#[DataProvider('getTestData')]references a static provider and the parameter list matches the row shapes, so these tests should execute unchanged after the upgrade.
121-136: Second test readjusted properlySame positive verdict for
testDecrIndent; nothing else to address here.
138-154: Third test updated consistently
testResetIncrmirrors the pattern—no issues spotted.
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Resolves #34
Summary by CodeRabbit
Chores
Tests