You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Enhanced rich hierarchical reporting for BDDfy #173
As an awesome pragmatic UI tester
I want to have the ability to include attachments into the BDDfy log
So that I will be able to view the screenshots and analyze the logs for Selenium WebDriver (or equivalent) tests.
Brief
Hierarchical logging: the user can expand and collapse the Step section inside the HTML report file to view the detailed logging:
Allow rich content inside the log file. Allow viewing images and open other attachments from the log file
Idea: Markdown processing before generating the HTML report?
The Examples feature looks amazing. I am not using BDDfy for almost a year, but still recommend the framework for everyone who asks my advice on starting they first test automation project.
I think, BDDfy is perfect for non-UI tests: unit tests, database integration tests, web services tests… However, I found is difficult to adopt the framework for Selenium WebDriver.
The problem: It was difficult to control and extend the logging. My dream was to:
Insert images and other attachments into the log
Apply custom formatting for the log
Here is a “prototype” in Word ;)
Nobody had solved this issue with logs and reports for WebDriver tests yet. And everybody are inventing their own wheels ;)
Activity
bondjasan commentedon Sep 25, 2019
Hi,
I implement screen shot in reports in this way (If someone have better solution, please send)
First, setup this in your tests (I use Nunit)
[OneTimeSetUp]
Configurator.StepExecutor = new ScreenShoter(path_to_image_folder);
Important method:
public override object Execute
using OpenQA.Selenium;
using System;
using System.IO;
using TestStack.BDDfy;
namespace SimpleTests.Utils
{
public class ScreenShoter : StepExecutor
{
private string path = string.Empty;
}
When tests is run, in exception message, image will appear inside step where exception is thrown.
Regards.
JeminJosephP commentedon Nov 17, 2020
@bondjasan
How do you get the instance of WebDriver in ScreenShoter class?