public void TestReadWriteOutOfBounds() { var memory = new ArrayMemory(5); Assert.Throws <IndexOutOfRangeException>(() => memory.write(6, true)); Assert.Throws <IndexOutOfRangeException>(() => memory.read(6)); }
public void TestReadWrite() { var memory = new ArrayMemory(1); memory.write(0, true); Assert.True(memory.read(0)); }