/** * @test * @expectedException \ConfigurationException */ public function throwsAnExceptionIfTargetIsCallableAndAddedRouteHasNoNameDefined() { $this->router->addRoute(Route::get('/something')->to(function () { // do nothing })); }