public void CanPinMultipleTimes() { _buffersList = new TransactionBuffersList(_bufferManager); var block = new Block(RandomFilename, 0); Assert.DoesNotThrow(() => { _buffersList.Pin(block); _buffersList.Pin(block); _buffersList.Pin(block); }); }
public void CanGetTransactionBuffer() { _buffersList = new TransactionBuffersList(_bufferManager); _ = _fileManager.Append(RandomFilename, out var block); Assert.DoesNotThrow(() => { _buffersList.Pin(block); }); var buffer = _buffersList.GetBuffer(block); Assert.IsNotNull(buffer); }
public void Pin(Block block) { _bufferList.Pin(block); }