Skip to content

Commit

Permalink
adjusting styles and corrected output path strategy
Browse files Browse the repository at this point in the history
  • Loading branch information
khalidumarr committed Aug 28, 2018
1 parent 7ed62a1 commit 0719924
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
6 changes: 6 additions & 0 deletions assets/Twig/css/app.min.css
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ p {
}
#top-nav.fixed {
position: fixed;
top: 0px;
left: 0;
right: 0;
z-index: 1000;
Expand Down Expand Up @@ -6913,4 +6914,9 @@ rotateX(-10deg);
50% {
color: #fff;
}
}

.feature
{
padding: 30px;
}
5 changes: 3 additions & 2 deletions src/Renderer/Behat2Renderer.php
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,7 @@ public function renderAfterStep($obj)
$suite = $obj->getCurrentSuite();
$feature = $obj->getCurrentFeature();
$scenario = $obj->getCurrentScenario();
$outputDir = $obj->getOutputPrinter()->getOutputPath();

$steps = $scenario->getSteps();
$step = end($steps); //needed because of strict standards
Expand Down Expand Up @@ -344,8 +345,8 @@ public function renderAfterStep($obj)
</div>';
$exception = $step->getException();
if(!empty($exception)) {
$relativeScreenshotPath = 'assets/screenshots/'. $suite->getName() .'/' . $feature->getScreenshotFolder() . '/' . $scenario->getScreenshotName();
$fullScreenshotPath = $obj->getBasePath() . '/results/html/' . $relativeScreenshotPath;
$relativeScreenshotPath = 'screenshots/' . $feature->getScreenshotFolder() . '/' . $scenario->getScreenshotName();
$fullScreenshotPath = $outputDir . '/' . $relativeScreenshotPath;
$print .= '
<pre class="backtrace">'.$step->getException().'</pre>';
if(file_exists($fullScreenshotPath))
Expand Down

0 comments on commit 0719924

Please sign in to comment.