public function Twig_Tests_Node_Expression_ConditionalTest::getTests in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/twig/twig/test/Twig/Tests/Node/Expression/ConditionalTest.php \Twig_Tests_Node_Expression_ConditionalTest::getTests()
Overrides Twig_Test_NodeTestCase::getTests
File
- vendor/twig/ twig/ test/ Twig/ Tests/ Node/ Expression/ ConditionalTest.php, line 26 
Class
Code
public function getTests() {
  $tests = array();
  $expr1 = new Twig_Node_Expression_Constant(1, 1);
  $expr2 = new Twig_Node_Expression_Constant(2, 1);
  $expr3 = new Twig_Node_Expression_Constant(3, 1);
  $node = new Twig_Node_Expression_Conditional($expr1, $expr2, $expr3, 1);
  $tests[] = array(
    $node,
    '((1) ? (2) : (3))',
  );
  return $tests;
}