I'd like to send a binary attachment to Report Portal with .net client. How can I do it?
Example is in Tests project.
https://github.com/reportportal/client-net/blob/master/ReportPortal.Client.Tests/LogItem/LogItem.cs
Find CreateLogWithAttach
test and see code.
var data = new byte[] { 1, 2, 3 };
var log = Service.AddLogItem(new AddLogItemRequest
{
TestItemId = _testId,
Text = "Log1",
Time = DateTime.UtcNow,
Level = LogLevel.Info,
Attach = new Attach("file1", "application/octet-stream", data)
});
Related documentation: Log Data in ReportPortal