rebus-org / Rebus.TestHelpers

:bus: Test helpers for Rebus (i.e. fake bus, saga fixture, etc.)
https://mookid.dk/category/rebus
Other
4 stars 2 forks source link

A bug in FakeRoutingApi.Defer method #1

Closed rsivanov closed 5 years ago

rsivanov commented 5 years ago

Hi

It seems that you have an error in FakeRoutingApi.Defer method. The current code: var messageSentToDestination = _factory.CreateEventGeneric( typeof(MessageSentToDestination<>), explicitlyRoutedMessage.GetType(), destinationAddress, delay, explicitlyRoutedMessage, optionalHeaders );

There should be typeof(MessageDeferredToDestination<>) instead of typeof(MessageSentToDestination<>).

mookid8000 commented 5 years ago

oh good catch! Thanks for reporting it 😄 would you like to fix it and submit a pull request?

mookid8000 commented 5 years ago

fixed by #2 – available in Rebus.TestHelpers 5.2.1

thanks for reporting & fixing 👍