picuscreative / testcafe-reporter-html

The HTML reporter for TestCafe
https://picuscreative.com/
22 stars 30 forks source link

Can Screenshots be embedded in this report for failed tests? #22

Closed skullz03 closed 4 years ago

skullz03 commented 5 years ago

Hi,

I have the following line in my package.json "test-with-html-reports": "testcafe chrome TestCafe-Demo/tests/ --reporter html:TestCafe-Demo/reports/html -e --proxy https.mycom.test.com:7000 -S -s artifacts/screenshots",

As you can see, I am making screenshots in the folder "artifacts" when the test fails. Could this be somehow shown in the report. Does this reporter plugin support that ?

chopra1203 commented 5 years ago

Hello, Are there any updates on this topic ? I am also looking for similar feature to include screen shots in HTML test reports.

martinkasa commented 5 years ago

@skullz03 @chopra1203 I have installed this library today and I can see screenshots of failed test in a report. HTML report and screenshot path are set on the same folder in my case. Maybe it works just in this setup.

timnederhoff commented 4 years ago

This is and old issue. screenshots are now embedded in the HTML.

RanjaniThoppe19 commented 4 years ago

Can you pls throw some light on this ? I am struggling to embed my screenshot in the report.

timnederhoff commented 4 years ago

OK, what command do you use to start your tests? what version do you use? Screenshots will be embedded automatically if you set the screenshot arguments correctly

RanjaniThoppe19 commented 4 years ago

I am a newbie , i use npm run testvideo (name of the testscript). testcafe version 1.8.5

RanjaniThoppe19 commented 4 years ago

Can you pls share how to set the screenshot arguments ?

timnederhoff commented 4 years ago

ok, If you have questions about running testcafe then please refer to the Testcafe docs

timnederhoff commented 4 years ago

this part can help you: https://devexpress.github.io/testcafe/documentation/reference/command-line-interface.html#-s-path---screenshots-path

RanjaniThoppe19 commented 4 years ago

Hurray ! I got it now, thank you so much !