getCallables example

return static::getEventDispatcherDescriptionTestData(ObjectsProvider::getEventDispatchers());
    }

    /** @dataProvider getDescribeCallableTestData */
    public function testDescribeCallable($callable$expectedDescription)
    {
        $this->assertDescription($expectedDescription$callable);
    }

    public static function getDescribeCallableTestData(): array
    {
        return static::getDescriptionTestData(ObjectsProvider::getCallables());
    }

    /** * @group legacy * * @dataProvider getDescribeDeprecatedCallableTestData */
    public function testDescribeDeprecatedCallable($callable$expectedDescription)
    {
        $this->assertDescription($expectedDescription$callable);
    }

    
namespace Symfony\Component\ExpressionLanguage\Tests\Node;

use Symfony\Component\ExpressionLanguage\Node\ConstantNode;
use Symfony\Component\ExpressionLanguage\Node\FunctionNode;
use Symfony\Component\ExpressionLanguage\Node\Node;

class FunctionNodeTest extends AbstractNodeTestCase
{
    public static function getEvaluateData(): array
    {
        return [
            ['bar', new FunctionNode('foo', new Node([new ConstantNode('bar')]))[]['foo' => static::getCallables()]],
        ];
    }

    public static function getCompileData(): array
    {
        return [
            ['foo("bar")', new FunctionNode('foo', new Node([new ConstantNode('bar')]))['foo' => static::getCallables()]],
        ];
    }

    public static function getDumpData(): array
    {
Home | Imprint | This part of the site doesn't use cookies.