public function testApiAddRule_CallsAddRuleOnAllBuses()
{
$matcher = function () {
};
$handler = function () {
};
$propagate = true;
$limit = 2;
$bus1 = $this->createChannelRouter();
$bus1->expects($this->once())->method('addRule')->with($matcher, $handler, $propagate, $limit);
$bus2 = $this->createChannelRouter();
$bus2->expects($this->once())->method('addRule')->with($matcher, $handler, $propagate, $limit);
$router = $this->createChannelRouterComposite(['bus1' => $bus1, 'bus2' => $bus2]);
$router->addRule($matcher, $handler, $propagate, $limit);
}