return [ new TwigFunction('array',
$this->
createArray(...
)),
new TwigFunction('version_compare',
version_compare(...
)),
];
} /**
* @param array<array-key, mixed> $array
*/
public function createArray(array
$array): ArrayFacade
{ return new ArrayFacade($array);
} public function getTests(): array
{ return [ // adds test: "var is true"
new TwigTest('true', null,
['node_class' => TrueTest::
class]),
// adds test: "var is false"
new TwigTest('false', null,
['node_class' => FalseTest::
class]),
// adds test: "var is array"
new TwigTest('array', null,
['node_class' => ArrayTest::
class]),