Example #1
0
 public void When_Set_Mapped_Fields_It_Is_Added_To_Primitive_Fields()
 {
     var customerMap = new DocumentMap<Customer>();
     customerMap.Map(c => c.Name);
     customerMap.Map(c => c.Address);
     Assert.AreEqual(2, customerMap.GetMappedFields().Count);
     Assert.IsTrue(customerMap.GetMappedFields().Any(m => m.Name == "Name" && m.Type == typeof(string)));
     Assert.IsTrue(customerMap.GetMappedFields().Any(m => m.Name == "Address" && m.Type == typeof(string)));
 }