/// <summary>
        /// Initailize all the necessary configuration for reporting
        /// </summary>
        public void InitReporting()
        {
            extentHtmlReporter = new  ExtentV3HtmlReporter(BDDReports.ReportFilePath);

            //initialize ExtentReports and attach the HtmlReporter
            extentRprt = new ExtentReports();
            extentRprt.AttachReporter(extentHtmlReporter);

            //To add system or environment info by using the setSystemInfo method.
            extentRprt.AddSystemInfo("Domain Name", Environment.UserDomainName);
            extentRprt.AddSystemInfo("OS  Platform", System.Environment.OSVersion.Platform.ToString());
            extentRprt.AddSystemInfo("OS  Version", System.Environment.OSVersion.ToString());
            extentRprt.AddSystemInfo("Machine Name", Environment.MachineName);
            extentRprt.AddSystemInfo("User Name", Environment.UserName);


            //set BDD report Style
            extentRprt.AnalysisStrategy = AnalysisStrategy.BDD;
            extentRprt.GherkinDialect   = "de";

            //configuration items to change the look and feel
            //add content, manage tests etc
            extentHtmlReporter.Config.DocumentTitle = BDDReports.ReportTitle;
            extentHtmlReporter.AnalysisStrategy     = AnalysisStrategy.Test;

            extentHtmlReporter.Start();
            extentHtmlReporter.Config.ReportName     = BDDReports.ReportDocName;
            extentHtmlReporter.Config.EnableTimeline = true;
            extentHtmlReporter.Config.Theme          = AventStack.ExtentReports.Reporter.Configuration.Theme.Dark;

            // Create Report featue and scenario
            extentFeature  = extentRprt.CreateTest <Feature>(BDDReports.ReportFeatureContext.FeatureInfo.Title);
            extentScenario = extentFeature.CreateNode <Scenario>(BDDReports.ReportScenarioContext.ScenarioInfo.Title);
        }
        public static void InitializeReport()
        {
            _logs = new List <string>();

            _report = new ReportLogs
            {
                Name = "Trade Me Sandbox Test Automation"
            };

            var reportsFilenamePrefix = "Trade Me Sandbox";

            var reportsDirectory = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Reports");

            if (!Directory.Exists(reportsDirectory))
            {
                Directory.CreateDirectory(reportsDirectory);
            }

            var reportsFilename = $"{reportsFilenamePrefix}_{DateTime.Now:yyyyMMdd_HHmmss}_Test Automation.html";

            var reportsPath = Path.Combine(reportsDirectory, reportsFilename);

            _v3HtmlReporter = new ExtentV3HtmlReporter(reportsPath);

            _v3HtmlReporter.LoadConfig(Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "extent-config.xml"));

            _v3HtmlReporter.Start();

            _extent = new ExtentReports();

            _extent.AttachReporter(_v3HtmlReporter);
        }
 public static void ReportSetup()
 {
     if (Properties.Test.Default.GenerateReport)
     {
         _report = new ReportLogs
         {
             Name = "AzureCalculator_API"
         };
         _v3HtmlReporter = ReportGenerator.InitializeReport("AzureCalculator_API");
         _v3HtmlReporter.Start();
         _extent = new ExtentReports();
         _extent.AttachReporter(_v3HtmlReporter);
     }
 }