public ExtentTest RecordPassStatus( string LogNote, string ScreenshotLocation, string TestCase, string description, Status TestStatus, ExtentTest test, DocX doc) { ScreenCaputres.TakeSreenShot(context, ScreenshotLocation + TestCase + ".png"); test.Log(TestStatus, LogNote); test.CreateNode(LogNote).Log(TestStatus, description).AddScreenCaptureFromPath("images\\" + TestCase + ".png"); Xceed.Words.NET.Image img = doc.AddImage(ScreenshotLocation + TestCase + ".png"); Picture p = img.CreatePicture(); //Create a new paragraph Paragraph par = doc.InsertParagraph(LogNote); p.HeightInches = 3.8; p.WidthInches = 6.5; par.AppendPicture(p); Paragraph desc = doc.InsertParagraph(description); par.Alignment = Alignment.center; par.FontSize(16); par.AppendLine("\n"); par.AppendLine("\n"); return(test); }
public ExtentTest RecordPassStatusExtent( string LogNote, Status TestStatus, string ScreenshotLocation, string TestCase, ExtentTest test) { ScreenCaputres.TakeSreenShot(context, ScreenshotLocation + TestCase + ".png"); test.Log(TestStatus, LogNote); test.CreateNode(LogNote).AddScreenCaptureFromPath("images\\" + TestCase + ".png"); return(test); }
/// <summary> /// Record Status for Word doc /// </summary> /// <param name="LogNote"></param> /// <param name="ScreenshotLocation"></param> /// <param name="TestCase"></param> /// <param name="doc"></param> public void RecordStepStatus( string LogNote, string ScreenshotLocation, string TestCase, DocX doc) { ScreenCaputres.TakeSreenShot(context, ScreenshotLocation + TestCase + ".png"); //Document Xceed.Words.NET.Image img = doc.AddImage(ScreenshotLocation + TestCase + ".png"); Picture p = img.CreatePicture(); //Create a new paragraph Paragraph par = doc.InsertParagraph(LogNote); p.HeightInches = 3.8; p.WidthInches = 6.8; par.AppendPicture(p); par.Alignment = Alignment.center; par.FontSize(16); par.AppendLine("\n"); par.AppendLine("\n"); }