to() public méthode

public to ( string | object | callable $eventListener )
$eventListener string | object | callable
 /**
  * @test
  * @expectedException \Prooph\ServiceBus\Exception\InvalidArgumentException
  */
 public function it_fails_on_setting_an_invalid_listener()
 {
     $router = new EventRouter();
     $router->to(null);
 }