Commit b2a73f4
committed
Fix FormTypeClassValidatorTest on PHPUnit 12.2 (Symfony 8.x CI matrix)
The captureMessages() helper stubbed ConstraintViolationBuilderInterface and
configured its setParameter() method. That method returns `static`, which the
PHPUnit version simple-phpunit pins on the Symfony 8.x matrix (12.2) cannot
configure via createStub() - it throws MethodCannotBeConfiguredException. It
passed locally only because we run PHPUnit 12.5.
Reuse the file's existing concrete ConstraintViolationBuilderStub (real fluent
methods, no mocking) - the same stub the other violation tests in this file
already use and which passes CI. Only the builder changes; the context stub,
which returns the interface (not static), is unaffected.1 parent 27861ac commit b2a73f4
1 file changed
Lines changed: 4 additions & 3 deletions
Lines changed: 4 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
199 | 199 | | |
200 | 200 | | |
201 | 201 | | |
202 | | - | |
203 | | - | |
204 | | - | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
205 | 206 | | |
206 | 207 | | |
207 | 208 | | |
| |||
0 commit comments