Skip to content

Add regression fixture for readonly promoted properties#54

Merged
TomasVotruba merged 1 commit into
mainfrom
regression-fixture-readonly-promoted-properties
Jul 20, 2026
Merged

Add regression fixture for readonly promoted properties#54
TomasVotruba merged 1 commit into
mainfrom
regression-fixture-readonly-promoted-properties

Conversation

@TomasVotruba

Copy link
Copy Markdown
Member

Reported case: constructor with 3 private readonly promoted properties on a single line was suspected of not being split.

Verified StandaloneLinePromotedPropertyFixer already handles it — this adds a fixture to lock the behavior in.

 final class ReadonlyPromotedProperties
 {
-    public function __construct(private readonly EntityManager $entityManager, private readonly SchedulerPlanner $schedulerPlanner, private readonly SchedulerRepository $schedulerRepository)
+    public function __construct(
+        private readonly EntityManager $entityManager,
+        private readonly SchedulerPlanner $schedulerPlanner,
+        private readonly SchedulerRepository $schedulerRepository
+    )
     {
     }
 }

Note for anyone hitting this: the rule sits at index 17 of SpacesLevel::RULES, so withSpacesLevel() below 17 never loads it.

@TomasVotruba
TomasVotruba enabled auto-merge (squash) July 20, 2026 09:43
@TomasVotruba
TomasVotruba merged commit e078617 into main Jul 20, 2026
8 checks passed
@TomasVotruba
TomasVotruba deleted the regression-fixture-readonly-promoted-properties branch July 20, 2026 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant