public void ChangeValueFact() { // Arrange var name = AutoFixture.String(); var oldValue = Guid.NewGuid(); var newValue = Guid.NewGuid(); var document = new BsonDocument(new BsonElement(name, oldValue)); // Act document.ChangeValue(name, newValue); var result = document.GetValue(name); // Assert result.Should().Be(newValue); }
protected override void DowngradeDocument(BsonDocument document) { document.ChangeValue("IsActive", true); }
protected override void DowngradeDocument(BsonDocument document) { document.ChangeValue("Kind", "Cat"); }
protected override void UpgradeDocument(BsonDocument document) { document.ChangeValue("IsActive", false); }
protected override void UpgradeDocument(BsonDocument document) { document.ChangeValue("Kind", "Dog"); }