PhpSpec\Loader\Node\ExampleNode::getTitle PHP Method

getTitle() public method

public getTitle ( ) : string
return string
    public function getTitle()
    {
        return $this->title;
    }

Usage Example

 function it_orders_an_array_of_example_nodes(ExampleNode $a, ExampleNode $b, ExampleNode $c)
 {
     $a->getTitle()->willReturn('bar1');
     $b->getTitle()->willReturn('bar2');
     $c->getTitle()->willReturn('bar3');
     $nodes = [$a, $b, $c];
     $expected = [$c, $b, $a];
     $this->setSpecificationTitle('foo');
     $this->filter($nodes)->shouldReturn($expected);
 }
All Usage Examples Of PhpSpec\Loader\Node\ExampleNode::getTitle