extent-framework / extentreports-cucumber4-adapter

Cucumber4 Adapter for Extent Framework
http://extentreports.com/docs/versions/4/java/cucumber2.html
Apache License 2.0
39 stars 22 forks source link

The adapter makes some weird folders to save screenshot #53

Closed vzenzo closed 4 years ago

vzenzo commented 4 years ago

So basically I have folders like Projects -project v1 -project v2 -project v3

My main test project is in project 3 folder, each time I run test the folder called project%20v3 is made and there it saves screenshots. The SparkReport and HTML report are saved in proper directory

I've tried everything, from mvn clean install, to reimportintg dependencies but it keeps saving them there. It used to work but when I made new version of project it messed up the screenshot path

My extent.properties file is

extent.reporter.html.start=true
extent.reporter.sparkstart=true

extent.reporter.html.config=src/test/resources/properties/configurations/html-config.html
extent.reporter.html.config=src/test/resources/properties/configurations/spark-config.html

extent.reporter.html.out=reports/extent/ExtentHtml.html
extent.reporter.html.out=reports/SparkReport/

screenshot.dir=reports/extent/
screenshot.rel.path=../
anshooarora commented 4 years ago

It would help if you can create a project and share the repository so I can investigate. Please use the below and revert back:

extent.reporter.spark.start=true
extent.reporter.spark.config=
extent.reporter.spark.out=./reports/extent/

screenshot.dir=./reports/extent/
screenshot.rel.path=./

Note: the adapter will try to locate the folder relative to your project basePath. So the above is valid if you have the following structure:

project
    /src
    /target
    /test-output
    /reports
        /extent
vzenzo commented 4 years ago

It would help if you can create a project and share the repository so I can investigate. Please use the below and revert back:

extent.reporter.spark.start=true
extent.reporter.spark.config=
extent.reporter.spark.out=./reports/extent/

screenshot.dir=./reports/extent/
screenshot.rel.path=./

Note: the adapter will try to locate the folder relative to your project basePath. So the above is valid if you have the following structure:

project
    /src
    /target
    /test-output
    /reports
        /extent

the problem was that if the project folder has space in name for example My Test, it will create My%20Test, but if you work in folder My_Test, it works fine.

anshooarora commented 4 years ago

Thanks for the update. Closing this, as its the same as #48.

duplicate #48