It still fails. Fortunately it's easy to reproduce with a test :-)
using System.Windows.Media;
using System.Windows.Media.Imaging;
using NUnit.Framework;
namespace MyNamespace
{
[TestFixture]
public class FailingTestClass
{
[Test]
public void FailingTest()
{
var bitmapSource =
BitmapSource.Create(10, 10, 96, 96, PixelFormats.Bgra32, null, new byte[10 * 10 * 4], 10 * 4);
}
}
}