Example #1
0
        public void MakeReservationReturnsCorrectResult(BookingViewModel sut)
        {
            RequestReservationCommand actual = sut.MakeReservation();
            var expected = sut.AsSource().OfLikeness <RequestReservationCommand>().Without(d => d.Id);

            expected.ShouldEqual(actual);
        }
Example #2
0
        public void PostSendsOnChannel(
            [Frozen] Mock <IChannel <RequestReservationCommand> > channelMock,
            BookingController sut,
            BookingViewModel model)
        {
            sut.Post(model);

            var expected = model.MakeReservation()
                           .AsSource().OfLikeness <RequestReservationCommand>()
                           .Without(d => d.Id)
                           .CreateProxy();

            channelMock.Verify(c => c.Send(expected));
        }
Example #3
0
 public void MakeReservationReturnsCorrectResult(BookingViewModel sut)
 {
     RequestReservationCommand actual = sut.MakeReservation();
     var expected = sut.AsSource().OfLikeness<RequestReservationCommand>().Without(d => d.Id);
     expected.ShouldEqual(actual);
 }