Error in 'com.cucumber.listner.ExtentCucumberFormatter

44 views Asked by At

I am running a script using Cucumber in BDD Framework and I am using Extent Reports plugin to create the execution report.

I've created the test runner class as below:

package com.e2eTests.automation;

import java.io.File;


import org.junit.AfterClass;
import org.junit.runner.RunWith;

import com.cucumber.listener.Reporter;

import io.cucumber.junit.Cucumber;
import io.cucumber.junit.CucumberOptions;

@RunWith(Cucumber.class)
@CucumberOptions(
        features = {"src/spec/features"},
        //glue = {""},
        plugin = {"pretty", "html:target/cucumber-html-report", "json:target/cucumber.json","com.cucumber.listner.ExtentCucumberFormatter:target/cucumber-reports/Bleu.html"},
        //plugin = {"pretty", "html:target/cucumber-html-report", },
        tags = ("@ver"),
        
        monochrome = true
        )
public class TestRunner {
    @AfterClass
    public static void writeExtentReport() {
        Reporter.loadXMLConfig(new File("src/test/resources/configs/extent-config.xml"));
        
    
    }

}

i have included the below dependency for the Extent report in the POM.xml file:

        <dependency>
        <groupId>com.aventstack</groupId>
        <artifactId>extentreports</artifactId>
        <version>3.1.3</version>
        <scope>provided</scope>
    </dependency>
    
    <dependency>
        <groupId>com.vimalselvam</groupId>
        <artifactId>cucumber-extentsreport</artifactId>
        <version>3.0.0</version>
    </dependency>

I am running the script with Junit and have the cucumber dependency for Junit too.

But when I execute the above runner class, its showing an error:

java.lang.IllegalArgumentException: The plugin specification 'com.cucumber.listner.ExtentCucumberFormatter:target/cucumber-reports/BleuHorizon.html' has a problem:

Could not load plugin class 'com.cucumber.listner.ExtentCucumberFormatter'.

Can anyone please help in this error and help to resolve it.

0

There are 0 answers