Skip to content

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

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

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

Triggered via pull request June 4, 2024 17:19
Status Failure
Total duration 47s
Artifacts

static-analysis.yaml

on: pull_request
Fit to window
Zoom out
Zoom in

Annotations

7 errors
PHPStan: src/ErrorTypesParser.php#L1
Ignored error pattern #^Parameter \#2 \$callback of function preg_replace_callback expects callable\(array<int\|string, string>\)\: string, Closure\(array\)\: mixed given\.$# in path /home/runner/work/sentry-symfony/sentry-symfony/src/ErrorTypesParser.php was not matched in reported errors.
PHPStan: src/ErrorTypesParser.php#L1
Ignored error pattern #^Parameter \#2 \$callback of function preg_replace_callback expects callable\(array\<int\|string, string\>\)\: string, Closure\(array\)\: mixed given\.$# in path /home/runner/work/sentry-symfony/sentry-symfony/src/ErrorTypesParser.php was not matched in reported errors.
PHPStan: src/EventListener/LoginListener.php#L1
Ignored error pattern #^Method Symfony\\Component\\Security\\Core\\Authentication\\Token\\TokenInterface\:\:isAuthenticated\(\) invoked with 1 parameter, 0 required\.$# in path /home/runner/work/sentry-symfony/sentry-symfony/src/EventListener/LoginListener.php was not matched in reported errors.
PHPStan: tests/EventListener/LoginListenerTest.php#L1
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 was not matched in reported 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#L220
Ignored error pattern #^Parameter \#3 \$roles of class Symfony\\Component\\Security\\Core\\Authentication\\Token\\SwitchUserToken constructor expects array\<string\>, string given\.$# in path /home/runner/work/sentry-symfony/sentry-symfony/tests/EventListener/LoginListenerTest.php is expected to occur 2 times, but occurred only 1 time.
PHPStan
Process completed with exit code 1.