public void SkipOneByteTest() { var stream = new FastStreamReader(new byte[5]); Assert.Equal(0, stream.GetCurrentIndex()); stream.SkipOneByte(); Assert.Equal(1, stream.GetCurrentIndex()); stream.SkipOneByte(); Assert.Equal(2, stream.GetCurrentIndex()); }
public void CompareBytesTest(byte[] data, byte[] other, bool skip, bool expected) { var stream = new FastStreamReader(data); if (skip) { stream.SkipOneByte(); } bool actual = stream.CompareBytes(other); Assert.Equal(expected, actual); }