Skip to content

fix(tests): deprecate warning in Symfony 5.4 for setAuthenticated #1184

fix(tests): deprecate warning in Symfony 5.4 for setAuthenticated

fix(tests): deprecate warning in Symfony 5.4 for setAuthenticated #1184

Re-run triggered June 3, 2024 12:27
Status Failure
Total duration 1m 1s
Artifacts

static-analysis.yaml

on: pull_request
Fit to window
Zoom out
Zoom in

Annotations

10 errors
PHPStan: tests/EventListener/LoginListenerTest.php#L1
Ignored error pattern #^Parameter \#5 \$originatedFromUri of class Symfony\\Component\\Security\\Core\\Authentication\\Token\\SwitchUserToken constructor expects string\|null, Sentry\\SentryBundle\\Tests\\EventListener\\AuthenticatedTokenStub given\.$# in path /home/runner/work/sentry-symfony/sentry-symfony/tests/EventListener/LoginListenerTest.php was not matched in reported errors.
PHPStan: tests/EventListener/LoginListenerTest.php#L222
Parameter #5 $originatedFromUri of class Symfony\Component\Security\Core\Authentication\Token\SwitchUserToken constructor expects string|null, Sentry\SentryBundle\Tests\EventListener\LegacyAuthenticatedTokenStub given.
PHPStan: tests/EventListener/LoginListenerTest.php#L289
No error to ignore is reported on line 289.
PHPStan: tests/EventListener/LoginListenerTest.php#L507
No error to ignore is reported on line 507.
PHPStan: tests/EventListener/LoginListenerTest.php#L512
Ignored error pattern #^Parameter \#1 \$user of method Symfony\\Component\\Security\\Core\\Authentication\\Token\\AbstractToken\:\:setUser\(\) expects Symfony\\Component\\Security\\Core\\User\\UserInterface, string\|Stringable\|Symfony\\Component\\Security\\Core\\User\\UserInterface given\.$# in path /home/runner/work/sentry-symfony/sentry-symfony/tests/EventListener/LoginListenerTest.php is expected to occur 1 time, but occurred 2 times.
PHPStan: tests/EventListener/LoginListenerTest.php#L534
No error to ignore is reported on line 534.
PHPStan: tests/EventListener/LoginListenerTest.php#L540
No error to ignore is reported on line 540.
PHPStan: tests/EventListener/LoginListenerTest.php#L545
Parameter #1 $user of method Symfony\Component\Security\Core\Authentication\Token\AbstractToken::setUser() expects Symfony\Component\Security\Core\User\UserInterface, string|Stringable|Symfony\Component\Security\Core\User\UserInterface given.
PHPStan
Process completed with exit code 1.
PHP-CS-Fixer
Process completed with exit code 8.