Plotly.NET icon indicating copy to clipboard operation
Plotly.NET copied to clipboard

Image comparing tests for ImageExport

Open WhiteBlackGoose opened this issue 3 years ago • 1 comments

There's Plotly.NET.Export which exports images, for example, into base64. However testing it on exact matches doesn't work well, after all, there are multiple ways the same image can be encoded with jpg or png.

So the idea here is to convert it to an image and compare pixel by pixel against a model one. If the deviation on average isn't big, then the test is considered to pass.

WhiteBlackGoose avatar Jul 04 '22 13:07 WhiteBlackGoose

Leaving this here, might be interesting: https://github.com/Codeuctivity/ImageSharp.Compare

kMutagene avatar Jul 11 '22 06:07 kMutagene