protected override void Because_of() { dynamic source = new DynamicDictionary(); source.Foo = "Foo"; source.Bar = "Bar"; _destination = Mapper.Map<Destination>(source); }
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(); }
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(); }