protected override void Because_of()
 {
     dynamic source = new DynamicDictionary();
     source.Foo = "Foo";
     source.Bar = "Bar";
     _destination = Mapper.Map<Destination>(source);
 }
예제 #2
0
 public void Should_map_existing_properties()
 {
     dynamic source = new DynamicDictionary();
     source.Foo = "Foo";
     _destination = Mapper.Map<Destination>(source);
     _destination.Foo.ShouldEqual("Foo");
     _destination.Bar.ShouldBeNull();
 }
예제 #3
0
 public void Should_map_existing_properties()
 {
     dynamic source = new DynamicDictionary();
     source.Foo = "Foo";
     var config = new MapperConfiguration(cfg => { });
     _destination = config.CreateMapper().Map<Destination>(source);
     _destination.Foo.ShouldEqual("Foo");
     _destination.Bar.ShouldBeNull();
 }