상속: extends Symfony\Component\EventDispatcher\Event
 /**
  * @param RunnerEvent $e
  *
  * @return void
  * @throws ProcessException
  */
 public function popStash(RunnerEvent $e)
 {
     if (!$this->isStashEnabled($e->getContext())) {
         return;
     }
     $this->doPopStash();
 }
예제 #2
0
 /**
  * @param RunnerEvent $event
  */
 public function startProgress(RunnerEvent $event)
 {
     $numberOftasks = $event->getTasks()->count();
     $this->progressBar->setFormat('<fg=yellow>%message%</fg=yellow>');
     $this->progressBar->setMessage('GrumPHP is sniffing your code!');
     $this->progressBar->start($numberOftasks);
 }
예제 #3
0
 function it_starts_progress(ProgressBar $progressBar, RunnerEvent $event, TasksCollection $tasks)
 {
     $tasks->count()->willReturn(2);
     $event->getTasks()->willReturn($tasks);
     $progressBar->setFormat(Argument::type('string'))->shouldBeCalled();
     $progressBar->setOverwrite(false)->shouldBeCalled();
     $progressBar->setMessage(Argument::type('string'))->shouldBeCalled();
     $progressBar->start(2)->shouldBeCalled();
     $this->startProgress($event);
 }
예제 #4
0
 /**
  * @param TasksCollection  $tasks
  * @param ContextInterface $context
  * @param array            $messages
  */
 public function __construct(TasksCollection $tasks, ContextInterface $context, array $messages)
 {
     parent::__construct($tasks, $context);
     $this->messages = $messages;
 }
예제 #5
0
 /**
  * @param TasksCollection $tasks
  * @param array           $messages
  */
 public function __construct(TasksCollection $tasks, array $messages)
 {
     parent::__construct($tasks);
     $this->messages = $messages;
 }