Closed cucumberQATester1428 closed 4 years ago
hi!
you specified:
extent.reporter.logger.start=true
but with
extent.reporter.logger.out=
i think you should specify the output dir of the logger.
you did specify
extent.reporter.bdd.out=test-output/ExtentBddReport
but this BDD reporter is not started
if you want the html report with the cucumber plugin you should:
extent.reporter.html.start=true
extent.reporter.html.out=output/report.html
Hi, I am facing the same issue, it does not create extent report folder under test-output.Below is my extent dependency in pom.xml file
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>${maven-compiler-plugin}</version>
<configuration>
<encoding>${utf-8}</encoding>
<source>${java-version}</source>
<target>${java-version}</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>${maven-surefire-plugin}</version>
<executions>
<execution>
<id>test</id>
<phase>test</phase>
<goals>
<goal>test</goal>
</goals>
<configuration>
<threadCount>4</threadCount>
<perCoreThreadCount>true</perCoreThreadCount>
<forkCount>4</forkCount>
<reuseForks>false</reuseForks>
<argLine>-Duser.language=en</argLine>
<argLine>-Xmx1024m</argLine>
<argLine>-XX:MaxPermSize=256m</argLine>
<argLine>-Dfile.encoding=UTF-8</argLine>
<useFile>false</useFile>
<includes>
<include>${testToRun}</include>
</includes>
<testFailureIgnore>true</testFailureIgnore>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>${mojo-exec-maven-plugin}</version>
<executions>
<execution>
<phase>test</phase>
<goals>
<goal>java</goal>
</goals>
</execution>
</executions>
<configuration>
<mainClass>com.cbs.test.ReportMerger</mainClass>
<arguments>
<argument>target/cucumber-report/</argument>
</arguments>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>${maven-resource-plugin}</version>
<configuration>
<!-- specify UTF-8, ISO-8859-1 or any other file encoding -->
<encoding>${utf-8}</encoding>
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
</resource>
</resources>
</configuration>
</plugin>
<plugin>
<groupId>net.masterthought</groupId>
<artifactId>maven-cucumber-reporting</artifactId>
<version>${maven-cucumber-reporting}</version>
<executions>
<execution>
<id>execution</id>
<phase>test</phase>
<goals>
<goal>generate</goal>
</goals>
<configuration>
<projectName>cucumbertests</projectName>
<outputDirectory>target/cucumber-report/cucumber-html-reports</outputDirectory>
<inputDirectory>target/cucumber-report</inputDirectory>
<jsonFiles>
<!-- supports wildcard or name pattern -->
<param>**/*cucumber.json</param>
</jsonFiles>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
<!-- Instructing the resources plugin to filter certain directories -->
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
</resource>
</resources>
<dependencies>
<dependency>
<groupId>com.aventstack</groupId>
<artifactId>extentreports-cucumber4-adapter</artifactId>
<version>1.0.7</version>
<exclusions>
<exclusion>
<groupId>io.cucumber</groupId>
<artifactId>cucumber-java</artifactId>
</exclusion>
<exclusion>
<groupId>io.cucumber</groupId>
<artifactId>cucumber-core</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>io.cucumber</groupId>
<artifactId>cucumber-java8</artifactId>
<version>${cucumber.version}</version>
</dependency>
<dependency>
<groupId>io.cucumber</groupId>
<artifactId>cucumber-testng</artifactId>
<version>${cucumber.version}</version>
<scope>test</scope>
</dependency>
And the runner class where I have the extent pluigin
package com.cbs.test;
import cucumber.api.CucumberOptions; import cucumber.api.testng.AbstractTestNGCucumberTests;
//import cucumber.api.CucumberOptions; //import cucumber.api.testng.AbstractTestNGCucumberTests;
@CucumberOptions(features = "target/test-classes", tags = { "@mobilesa" }, monochrome = true, plugin = { "pretty", "html:target/cucumber-report/webapp", "json:target/cucumber-report/webapp/cucumber.json", "rerun:target/cucumber-report/webapp/rerun.txt", "com.aventstack.extentreports.cucumber.adapter.ExtentCucumberAdapter:" }, glue = { "com.cbs.test.framework.hooks", "com.cbs.test.step_definitions.mobile" }) public class RunAndroidAppSuite extends AbstractTestNGCucumberTests {
public RunAndroidAppSuite() {
DriverObject.android();
}
}
extent.properties:
extent.reporter.html.start=true
extent.reporter.logger.start=true
extent.reporter.spark.start=true
extent.reporter.html.config=src/test/resources/extent-config.xml extent.reporter.logger.config=src/test/resources/extent-config.xml extent.reporter.spark.config=src/test/resources/extent-config.xml
extent.reporter.html.out=test-output/HtmlReport/ExtentHtml.html extent.reporter.logger.out=test-output/Logger extent.reporter.spark.out=test-output/Spark
screenshot.dir=test-output/HtmlReport/
Could you please look into the issue?
Hi - what is the location of extent.properties
?
Also - please use only 1 type of Reporter. Multiple Rich reporters are not supported.
extent.reporter.html.start=false
extent.reporter.logger.start=false
extent.reporter.spark.start=true
I am facing this issue. unable to generate the report. No error is displayed
i'm also facing issue only spark and pdf reports generated
below is my extent.properties file
extent.reporter.spark.start=true extent.reporter.spark.out=target/SparkReport/Spark.html
extent.reporter.pdf.start=true extent.reporter.pdf.out=target/PdfReport/ExtentPdf.pdf
extent.reporter.html.start=true extent.reporter.html.out=target/extent/HtmlReport/ExtentHtml.html
extent.reporter.bdd.start=true extent.reporter.bdd.out=target/extent/BddReport/
Hi could someone please help with the resolution of this issue I just started using extent report adapter 4 in my project and when I run a scenario I am seeing Passed 0 failed 0 and no error same happened with cucumber >6 version but I couldnt resolve that
Please help me in fixing this issue
Cucumber4-Adapter is not generating the desired extent report in the test-output folder only index.html report is being generated
package mortgage.runners;
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions; import cucumber.api.junit.Cucumber;
@RunWith(Cucumber.class) @CucumberOptions( plugin = {"pretty" , "html:target/CucumberResults", "com.aventstack.extentreports.cucumber.adapter.ExtentCucumberAdapter:"}, features = {"./src/test/resources/features/"}, glue = {"mortgage.stepdefinitions"}, //dryRun = true, tags = "@RegressionTest", monochrome = true)
public class CukesRunner {
}
This the pom.xml <?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
Below is the extent.properties file
extent.properties
for more details about this file go to:
http://extentreports.com/docs/versions/4/java/extentservice.html
extent.reporter.avent.start=false extent.reporter.bdd.start=false extent.reporter.cards.start=false extent.reporter.email.start=false extent.reporter.html.start=false extent.reporter.klov.start=false extent.reporter.logger.start=true extent.reporter.tabular.start=false
extent.reporter.avent.config=src/test/resources/extent-config.xml extent.reporter.bdd.config= extent.reporter.cards.config= extent.reporter.html.config= extent.reporter.klov.config= extent.reporter.logger.config= extent.reporter.tabular.config=
extent.reporter.avent.out= extent.reporter.bdd.out=test-output/ExtentBddReport extent.reporter.cards.out= extent.reporter.email.out= extent.reporter.html.out= extent.reporter.logger.out= extent.reporter.tabular.out=test-output/LoggerReport