Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Minor.

  • Loading branch information...
commit 963a45f9b27019e69e2c952b58d8e9aaecb940bf 1 parent 51b1b70
Steve Wagner lanwin authored
18 source/MongoDB.Tests/UnitTests/Serialization/SerializationFactoryTests.cs
View
@@ -51,5 +51,23 @@ public void CanNotCreateObjectFromPrivateConstructor()
Assert.IsNotNull(obj);
}
+
+ public class SetProtectedPropertys
+ {
+ protected double Property { get; set; }
+
+ public double GetProperty() {return Property; }
+ }
+
+ [Test]
+ public void CanSetProtectedProperty()
+ {
+ var bson = Serialize(new Document("Property", 4));
+
+ var prop = Deserialize<SetProtectedPropertys>(bson);
+
+ Assert.IsNotNull(prop);
+ Assert.AreEqual(4, prop.GetProperty());
+ }
}
}
Please sign in to comment.
Something went wrong with that request. Please try again.