public void TestNamedIdMemberConventionWithTestClassB() { var convention = new NamedIdMemberConvention("Id", "id", "_id"); var classMap = new BsonClassMap<TestClassB>(); convention.Apply(classMap); Assert.Null(classMap.IdMemberMap); }
public void TestNamedIdMemberConventionWithTestClassD() { var convention = new NamedIdMemberConvention("Id", "id", "_id"); var classMap = new BsonClassMap<TestClassD>(); convention.Apply(classMap); Assert.IsNotNull(classMap.IdMemberMap); Assert.AreEqual("_id", classMap.IdMemberMap.MemberName); }