PhpSpec\Event\ExampleEvent::getTime PHP Method

getTime() public method

public getTime ( ) : float
return float
    public function getTime()
    {
        return $this->time;
    }

Usage Example

Exemplo n.º 1
0
 protected function printSlowTime(ExampleEvent $event)
 {
     $io = $this->getIO();
     $ms = $event->getTime() * 1000;
     if ($ms > 100) {
         $io->write(sprintf(' <failed>(%sms)</failed>', round($ms)));
     } elseif ($ms > 50) {
         $io->write(sprintf(' <pending>(%sms)</pending>', round($ms)));
     }
 }
All Usage Examples Of PhpSpec\Event\ExampleEvent::getTime