phpstan-drupal icon indicating copy to clipboard operation
phpstan-drupal copied to clipboard

RenderCallbackRule: Check if method exists in trustedCallbacks

Open Boegie opened this issue 1 year ago • 1 comments

Resolves #561

Boegie avatar May 12 '23 15:05 Boegie

😩

     Internal error: Internal error: Method of class                                                  
     Drupal\Tests\Core\Render\PlaceholdersTest cannot be used as the class                            
     does not exist in file                                                                           
     /home/runner/work/_temp/drupal/core/tests/Drupal/Tests/Core/Render/PlaceholderGeneratorTest.php  

That is because PlaceholdersTest is in core/tests/Drupal/Tests/Core/Render/RendererTestBase.php. The test class \Drupal\Tests\Core\Render\PlaceholderGeneratorTest extends \Drupal\Tests\Core\Render\RendererTestBase. But it's not brought into scope.

mglaman avatar Jun 28 '23 21:06 mglaman