extent-framework / extentreports-csharp

Extent Reporting Library, .NET
http://extentreports.com
Apache License 2.0
50 stars 40 forks source link

Change "path" argument to getting special chars #31

Closed CMALD closed 5 years ago

CMALD commented 5 years ago

Hello,

I try run this:

testAction.Log(Status.Info , "Click On", MediaEntityBuilder.CreateScreenCaptureFromPath(@"E:2. Click on 'loginButton'.Jpeg").Build());

But the screenshot image didn't attached to the report,

Only when I change the image name to: "2 Click on loginButton.Jpeg" and respectively the code to:

testAction.Log(Status.Info , "Click On", MediaEntityBuilder.CreateScreenCaptureFromPath(@"E:\2 Click on loginButton.Jpeg").Build());

without special chars; point and apostrophe, only then the report attaches the screenshot file.

Is it possible to add support in special chars for path string arguments?

This issue relevant to below functions

  1. CreateScreenCaptureFromPath, CreateScreenCaptureFromPath
  2. Constructors of all report types
anshooarora commented 5 years ago

This is not possible as the browser will not show the image. Extent cannot control what happens after it sets the path, its up to the browser to show it.