/** * Prints scenarios summary information. * * @param LoggerDataCollector $logger suite logger */ protected function printScenariosSummary(LoggerDataCollector $logger) { parent::printScenariosSummary($logger); if ('JENKINS' === getenv('BEHAT_CONTEXT')) { $this->write(sprintf("[1;37m##glados_scenario##%s##glados_scenario##[0m", json_encode($logger->getScenariosStatuses()))); } }
/** * {@inheritdoc} */ public static function getSubscribedEvents() { $events = parent::getSubscribedEvents(); // Skip printing output for steps unset($events['afterStep']); $events['afterFeature'] = 'afterFeature'; return $events; }
public function afterSuite(SuiteEvent $event) { parent::afterSuite($event); $logger = $event->getLogger(); $this->writeln("\n{+passed}Behat Steps Analysis{-passed}"); $this->writeln('===================='); $this->printStepsUsages($logger); $this->printMergeableSteps($logger); }
/** * Adding beforeSuite event. * * @return array The event names to listen to. */ public static function getSubscribedEvents() { $events = parent::getSubscribedEvents(); $events['beforeSuite'] = 'beforeSuite'; return $events; }