예제 #1
0
 protected override void Because_of()
 {
     sourceMember =
         ConfigProvider.FindTypeMapFor <Source, Destination>()
         .GetPropertyMaps()
         .Single(pm => pm.DestinationProperty.Name == memberName)
         .SourceMember;
 }
예제 #2
0
 protected override void Because_of()
 {
     try
     {
         sourceMember =
             ConfigProvider.FindTypeMapFor <Source, Destination>()
             .GetPropertyMaps()
             .Single(pm => pm.DestinationProperty.Name == "Ignored")
             .SourceMember;
     }
     catch (Exception ex)
     {
         exception = ex;
     }
 }
예제 #3
0
        public void Should_only_map_source_members()
        {
            var typeMap = ConfigProvider.FindTypeMapFor <Source, Destination>();

            typeMap.GetPropertyMaps().Count().ShouldBe(1);
        }