/**
  * Handles the request
  *
  * @return void
  * @author Robert Lemke <*****@*****.**>
  */
 public function handleRequest()
 {
     $request = $this->requestBuilder->build();
     $response = $this->objectFactory->create('F3\\FLOW3\\MVC\\CLI\\Response');
     $this->dispatcher->dispatch($request, $response);
     $response->send();
 }
 /**
  * @test
  * @author Karsten Dambekalns <*****@*****.**>
  */
 public function argumentsAreDetectedIfNoOptionsAreGiven()
 {
     $this->mockRequest->expects($this->once())->method('setControllerPackageKey')->with('TestPackage');
     $this->mockRequest->expects($this->once())->method('setCommandLineArguments')->with(array('file1', 'file2'));
     $this->environment->SERVER['argc'] = 6;
     $this->environment->SERVER['argv'][0] = 'index.php';
     $this->environment->SERVER['argv'][1] = 'TestPackage';
     $this->environment->SERVER['argv'][3] = '--';
     $this->environment->SERVER['argv'][4] = 'file1';
     $this->environment->SERVER['argv'][5] = 'file2';
     $this->requestBuilder->build();
 }