Esempio n. 1
0
        public void ShouldPutDoubleToNativeBuffer(IAtomicBuffer buffer)
        {
            buffer.PutDouble(Index, DoubleValue);

            var valueAsLong   = Marshal.ReadInt64(buffer.BufferPointer, Index);
            var valueAsDouble = BitConverter.ToDouble(BitConverter.GetBytes(valueAsLong), 0);

            Assert.That(valueAsDouble, Is.EqualTo(DoubleValue));
        }