Пример #1
0
        public static InMemoryHouseRepository CreateDummyInMemoryHouseRepository()
        {
            var dummy = new InMemoryHouseRepository();

            dummy.Save(new House {
                Id = 45474845, Address = "Dam 1, Amsterdam", Leads = { }
            });
            return(dummy);
        }
Пример #2
0
        static void Main(string[] args)
        {
            var dummy = new InMemoryHouseRepository();

            dummy.Save(new House {
                Id = 45474845, Address = "Dam 1, Amsterdam", Leads = { }
            });

            var controller =
                new AgentController(
                    new ContactAgentInteractor(
                        new ContactAgentRequestMessageValidator(),
                        dummy),
                    new ContactAgentResponsePresenter());

            controller.Contact(
                new ContactAgentRequestMessage
            {
                CustomerEmailAddress = "*****@*****.**",
                CustomerPhoneNumber  = 555123456,
                HouseId = 45474845
            }
                );
        }