extentreports-csharp icon indicating copy to clipboard operation
extentreports-csharp copied to clipboard

Another crash at Flush()

Open Jens-G opened this issue 2 years ago • 1 comments

System.MissingMethodException : Method not found: 'System.Runtime.CompilerServices.CallSiteBinder Microsoft.CSharp.RuntimeBinder.Binder.Convert(Microsoft.CSharp.RuntimeBinder.CSharpBinderFlags, System.Type, System.Type)'.

Jens-G avatar Jul 03 '23 07:07 Jens-G

Can you give it a try with the latest beta and revert back if you continue to face this issue?

https://www.nuget.org/packages/ExtentReports/5.0.0-beta2

Please note: with version 5, ExtentHtmlReporter is deprecated and ExtentSparkReporter is the replacement. So the above code will change slightly:

using AventStack.ExtentReports;
using AventStack.ExtentReports.Reporter;

var extent = new ExtentReports();
var htmlReporter = new ExtentSparkReporter("index.html");
extent.AttachReporter(htmlReporter);
extent.CreateTest("MyFirstTest").Pass("details");
extent.Flush();

anshooarora avatar Sep 01 '23 15:09 anshooarora