private void RefreshPreview()
        {
            _previousCursor      = Mouse.OverrideCursor;
            Mouse.OverrideCursor = Cursors.Wait;

            HTMLReportsConfiguration currentConf = WorkSpace.Instance.Solution.HTMLReportsConfigurationSetList.Where(x => (x.IsSelected == true)).FirstOrDefault();

            //changing the solution because report should not be created in installtion folder due to permissions issues + it can be multiple users will run same Ginger on server
            if (Directory.Exists(mPreviewDummyReportPath))
            {
                ClearDirectoryContent(mPreviewDummyReportPath);
            }
            else
            {
                PrepareDummyReportData();
            }

            Ginger.Reports.GingerExecutionReport.ExtensionMethods.CreateGingerExecutionReport(new ReportInfo(mPreviewDummyReportDataPath),
                                                                                              false,
                                                                                              _HTMLReportConfiguration,
                                                                                              mPreviewDummyReportPath, false, currentConf.HTMLReportConfigurationMaximalFolderSize);

            WBP = new WebBrowserPage();
            frmBrowser.Content = WBP;
            browser            = WBP.GetBrowser();
            browser.Navigate(System.IO.Path.Combine(mPreviewDummyReportPath, "GingerExecutionReport.html"));

            Mouse.OverrideCursor = _previousCursor;
        }
Ejemplo n.º 2
0
        public MiniBrowserWindow()
        {
            InitializeComponent();

            WBP = new WebBrowserPage();
            BrowserFrame.Content = WBP;
        }