/** * @param null $title */ public function takeResponsiveScreenshots($title = null) { if (!$title) { $title = $this->title(); } $sizes = Xtest::getArg('breakpoints', $this->getSeleniumConfig('screenshot/breakpoints')); foreach (explode(',', $sizes) as $size) { list($w, $h) = explode('x', $size); $this->resizeBrowserWindow((int) $w, (int) $h); $this->takeScreenshot($title . ' w' . $w); } }
protected function runTest() { try { return parent::runTest(); } catch (Exception $e) { if (Xtest::getArg('debug')) { echo PHP_EOL . "got '" . $e->getMessage() . "' exception. press any key to continue.." . PHP_EOL; ob_end_flush(); fgets(STDIN); } throw $e; } }
/** * @return bool */ protected function allowExternal() { return Xtest::getArg('external'); }