public void Initialize() { var mocker = new AutoMocker(); homeDelivery = mocker.CreateInstance <Concrete1>(); upsDelivery = mocker.CreateInstance <Concrete2>(); personMock = mocker.CreateInstance <Person>(); }
public HomeController([Dependency("Concrete1")] IShippingType homeDelivery, [Dependency("Concrete2")] IShippingType upsDelivery, IPerson person) { this.homeDelivery = homeDelivery; this.upsDelivery = upsDelivery; this.person = person; }
public ValuesController([Dependency("Concrete1")] IShippingType shippingType) { homeDelivery = shippingType; }
public ShippingController([Dependency("Concrete1")] IShippingType homeDelivery) { this.homeDelivery = homeDelivery; }
public ShippingController() { homeDelivery = new Concrete1(); }