public virtual void TestReadLongForPositionEndianness() { var readLong = _input.ReadLong(2, Endianness.LittleEndian); var longB = BytesExtensions.ReadLongL(InitData, 2); Assert.AreEqual(longB, readLong); }
public virtual void TestWriteLongForVEndianness() { long expected = 100; _output.Write(2, expected, Endianness.LittleEndian); var actual = BytesExtensions.ReadLongL(_output.Buffer, 2); Assert.AreEqual(actual, expected); }
public virtual void TestWriteDoubleForVEndianness() { var v = 1.1d; _output.Write(v, Endianness.LittleEndian); var theLong = BitConverter.DoubleToInt64Bits(v); var readLongB = BytesExtensions.ReadLongL(_output.Buffer, 0); Assert.AreEqual(theLong, readLongB); }