public void SaveWebDriverScreenShotTest()
 {
     var downloadPage = new InternetPage(this.DriverContext).OpenHomePage().GoToFileDownloader();
     var screenShotNumber = FilesHelper.CountFiles(this.DriverContext.ScreenShotFolder, FileType.Png);
     downloadPage.SaveWebDriverScreenShot();
     var nameOfScreenShot = downloadPage.CheckIfScreenShotIsSaved(screenShotNumber);
     Assert.IsTrue(nameOfScreenShot.Contains(this.DriverContext.TestTitle), "Name of screenshot doesn't contain Test Title");
 }
        public void SaveWebDriverScreenShotTest()
        {
            var downloadPage     = new InternetPage(this.DriverContext).OpenHomePage().GoToFileDownloader();
            var screenShotNumber = FilesHelper.CountFiles(this.DriverContext.ScreenShotFolder, FileType.Png);

            Assert.IsNotNull(downloadPage.SaveWebDriverScreenShot());
            var nameOfScreenShot = downloadPage.CheckIfScreenShotIsSaved(screenShotNumber);

            Assert.IsTrue(nameOfScreenShot.Contains(this.DriverContext.TestTitle), "Name of screenshot doesn't contain Test Title");
        }
        public void SaveFullScreenShotTest()
        {
            var downloadPage     = new InternetPage(this.DriverContext).OpenHomePage().GoToFileDownloader();
            var screenShotNumber = FilesHelper.CountFiles(this.DriverContext.ScreenShotFolder, FileType.Png);

            Assert.IsNotNull(TakeScreenShot.Save(TakeScreenShot.DoIt(), ImageFormat.Png, this.DriverContext.ScreenShotFolder, string.Format(CultureInfo.CurrentCulture, this.DriverContext.TestTitle + "_first")));
            var nameOfScreenShot = downloadPage.CheckIfScreenShotIsSaved(screenShotNumber);

            Assert.IsTrue(nameOfScreenShot.Contains(this.DriverContext.TestTitle), "Name of screenshot doesn't contain Test Title");
            Assert.IsNotNull(this.DriverContext.TakeAndSaveScreenshot());
        }