public LoginCredentialsDTO MapFrom(IHttpRequest input) { return(new LoginCredentialsDTO( input.ParsePayloadFor(PayloadKeys.For("uxUserNameTextBox")), input.ParsePayloadFor(PayloadKeys.For("uxPasswordTextBox")) )); }
public SubmitLeaseRequestDTO MapFrom(IHttpRequest input) { return(new SubmitLeaseRequestDTO( input.ParsePayloadFor(PayloadKeys.CustomerId), input.ParsePayloadFor(PayloadKeys.SlipId), input.ParsePayloadFor(PayloadKeys.For("uxLeaseDuration")) )); }
public BoatRegistrationDTO MapFrom(IHttpRequest input) { return(new BoatRegistrationDTO( input.ParsePayloadFor(PayloadKeys.For("uxRegistrationNumberTextBox")), input.ParsePayloadFor(PayloadKeys.For("uxManufacturerTextBox")), input.ParsePayloadFor(PayloadKeys.For("uxModelYearTextBox")), input.ParsePayloadFor(PayloadKeys.For("uxLengthTextBox")), input.ParsePayloadFor(PayloadKeys.CustomerId) )); }
public void Should_map_username_from_request( ) { using (mockery.Record( )) { Expect.Call(mockRequest.ParsePayloadFor(PayloadKeys.For("uxUserNameTextBox"))).Return(null); Expect.Call(mockRequest.ParsePayloadFor(PayloadKeys.For("uxPasswordTextBox"))).Return(null); } using (mockery.Playback( )) { CreateSUT( ).MapFrom(mockRequest); } }
public UpdateCustomerRegistrationDTO MapFrom(IHttpRequest input) { return(new UpdateCustomerRegistrationDTO( input.ParsePayloadFor(PayloadKeys.CustomerId), input.ParsePayloadFor(PayloadKeys.For("uxUserNameTextBox")), input.ParsePayloadFor(PayloadKeys.For("uxPasswordTextBox")), input.ParsePayloadFor(PayloadKeys.For("uxFirstNameTextBox")), input.ParsePayloadFor(PayloadKeys.For("uxLastNameTextBox")), input.ParsePayloadFor(PayloadKeys.For("uxPhoneNumberTextBox")), input.ParsePayloadFor(PayloadKeys.For("uxCityTextBox")) )); }
public PayloadKey <string> Create(string controlId) { return(PayloadKeys.For(controlId)); }