/** * @param object $request * * @return mixed */ protected function dispatchRequest($request) { $requestClass = get_class($request); $handle = $this->inflector->inflect($requestClass); return $handle->handle($request); }
/** @test */ public function should_get_handler_name_from_command() { $command = new CommandStub(new stdClass()); $handler = $this->inflector->inflect($command); $this->assertEquals('Cribbb\\Stubs\\HandlerStub', $handler); }