public void InMemoryValuesStore_Update_ValueDoesntExist()
        {
            // Arrange
            var valuesStore = new InMemoryValuesStore();
            var value       = new Value()
            {
                Id = "nonExistentId", Data = "data"
            };

            // Act
            Action action = () => valuesStore.Update(value);

            // Assert
            ExceptionAssert.ThrowsApiException(action, ApiExceptionError.ValueDoesntExist);
        }
        public void InMemoryValuesStore_Update_Success()
        {
            // Arrange
            var value = new Value()
            {
                Id = "1", Data = "data"
            };
            var valuesStore = new InMemoryValuesStore();

            valuesStore.Create(value);

            var updatedValue = "updatedData";

            // Act
            value.Data = updatedValue;
            valuesStore.Update(value);

            // Assert
            var readValue = valuesStore.Read(value.Id);

            Assert.AreEqual(value.Id, readValue.Id);
            Assert.AreEqual(updatedValue, readValue.Data);
        }