I get Cannot resolve symbol 'ExtentHtmlReporter' message for
com.aventstack.extentreports.reporter.ExtentHtmlReporter;
I added below dependency and I was able to import below imports successfully.
import com.aventstack.extentreports.ExtentTest;
import com.aventstack.extentreports.Status;
import com.aventstack.extentreports.reporter.configuration.Theme;
However, below import is not listed.
import com.aventstack.extentreports.reporter.ExtentHtmlReporter;
<!-- https://mvnrepository.com/artifact/com.aventstack/extentreports -->
<dependency>
<groupId>com.aventstack</groupId>
<artifactId>extentreports</artifactId>
<version>5.0.6</version>
</dependency
Found the answer in https://sqa.stackexchange.com/questions/46834/unable-to-import-extenthtmlreporter-for-the-java-class
ExtentHtmlReporter, ExtentLoggerReporter The ExtentHtmlReporter and ExtentLoggerReporter were deprecated in series 4.1.x and have been removed in version 5. The replacement is ExtentSparkReporter, which is comprehensive, ports all features along with a host of new ones.
ExtentSparkReporter spark = new ExtentSparkReporter("Spark.html");
Or downgrade to 4.0.9