Ejemplo n.º 1
0
        public void ShouldCompareAndSetIntToNativeBuffer(IAtomicBuffer buffer)
        {
            Marshal.WriteInt32(buffer.BufferPointer, Index, IntValue);

            Assert.True(buffer.CompareAndSetInt(Index, IntValue, IntValue + 1));

            Assert.That(Marshal.ReadInt32(buffer.BufferPointer, Index), Is.EqualTo(IntValue + 1));
        }