protected function processSecurity() { $this->auth = CMSAuth::getInstance(); // ignore security settings in command line mode if ($this->dispatcher->getRequest() instanceof \Faid\Request\CommandLineRequest) { return; } if (self::isUnitTestsRunning()) { return; } \Trace::addMessage('CMS', 'Проверка безопасности'); if ($this->dispatcher->getRequest() instanceof Request) { $this->dispatcher->getRequest()->testForInjections(); $this->dispatchGranted = $this->showAuthScreenIfNecessary(); } \Extasy\Audit\DDosDetector::detect(); }
public function testGetRequest() { $request = new Request(array('phrase1' => 'Hello', 'phrase2' => 'World')); $dispatcher = new Dispatcher($request); $this->assertEquals($request, $dispatcher->getRequest()); }