public void it_should_map_props_of_same_name() { var src = new SimpleSource() { Name = "mikey" }; var cfg = new DestinationConfiguration(typeof(SimpleDestination)); cfg.From(typeof(SimpleSource)); var executable = cfg.ToExecutable(src.GetType()); var mapper = new DefaultMapCommand(executable, new TestContextualizer()); var output = (SimpleDestination)mapper.From(src); output.Name.should_be_equal_to("mikey"); }
public void it_should_map_props_of_same_name() { var src = new SimpleSource() {Name = "mikey"}; var cfg = new DestinationConfiguration(typeof(SimpleDestination)); cfg.From(typeof (SimpleSource)); var executable = cfg.ToExecutable(src.GetType()); var mapper = new DefaultMapCommand(executable,new TestContextualizer()); var output = (SimpleDestination) mapper.From(src); output.Name.should_be_equal_to("mikey"); }