public EndpointConsole(Stories.Interfaces.IEndpointPersistence endpointPersistence) { this.createEndpoint = new CreateEndpoint(endpointPersistence); this.listAllEndpoints = new ListAllEndpoints(endpointPersistence); this.validateSerialNumberOfEndpoint = new ValidateSerialNumberOfEndpoint(endpointPersistence); this.searchBySerialNumber = new SearchBySerialNumber(endpointPersistence); this.editStateEndpoint = new EditStateEndpoint(endpointPersistence); this.deleteEndpoint = new DeleteEndpoint(endpointPersistence); }
public void MustEditStateAendpoint() { //arrange PersistenceMock persistenceMock = new PersistenceMock(); persistenceMock.SearchBySerialNumber(); var editEndpoint = new EditStateEndpoint(persistenceMock.EditStateEndpoint()); //action editEndpoint.Execute(ModelsMock.EndpointMock().SerialNumber, ModelsMock.EndpointMock().State); //assert Assert.Empty(editEndpoint.Error); }