Add some custom text to logs shown by protractor-beautiful-reporter

Viewed 452

I'm using protractor-beautiful-reporter and would like to know if there's a way of adding my own logs into the html report is generates.

For now, I don't find it really practical since it shows messages like TimeoutError: Wait timed out after 5009ms while my custom logs would show something like ERROR: the login popup did not show.

Thanks in advance for your insights!

1 Answers

I hope I understand your question correctly, so, you have to add reporting capabilities to your Jasmine scripts with additional node modules if you are looking for customized reports.

Depending on what kind of reporting you are looking for, you can use any of the npm modules readily available and create your own custom framework with Protractor and Jasmine.

Some of the commonly used npm modules for reporting:

Most of these reporters can be used to generate HTML, XML reports of the test run, take screenshots on spec failures or format the basic run status in your console.

Further, you can use the generated XML files to integrate with your CI tools as well.

Basically, you have the freedom to choose and create your own custom framework according to your needs.

Related