public void Test3()
{
MemoryStream ms = new MemoryStream();
BlockAllocatedMemoryStream ms2 = new BlockAllocatedMemoryStream();
for (int x = 0; x < 10000; x++)
{
long position = Random.Int64Between(0, 100000);
ms.Position = position;
ms2.Position = position;
int value = Random.Int32;
ms.Write(value);
ms2.Write(value);
long length = Random.Int64Between(100000 >> 1, 100000);
ms.SetLength(length);
ms2.SetLength(length);
}
Compare(ms, ms2);
}