Fork me on GitHub

Executing Commands Edit on GitHub

If all you need to do is to execute the full behavior chain for a message, in process, and right now, you can use the IServiceBus.Consume() method as shown below:

public void consume(IServiceBus bus)
    // Execute the entire chain for a message
    // synchronously and in the local application
    bus.Consume(new PingMessage());

This mechanism is frequently useful for automated integration testing. Do note that FubuMVC will throw an exception if the running application does not have a handler chain for that message type.