/**
  * Registers the application services.
  *
  * @return void
  */
 public function register()
 {
     $this->app->singleton('broker', function (Application $app) {
         $config = $app->make('config');
         $driver = $config->get('broker.driver');
         $params = $config->get('broker.connections.' . $driver);
         return BrokerFactory::make($params);
     });
 }
Exemple #2
0
 /**
  * @expectedException InvalidArgumentException
  */
 public function testInvalidParameters()
 {
     BrokerFactory::make(['foo' => 'bar']);
 }