Ejemplo n.º 1
0
 /**
  * Constructor swaps the SecurityConfiguration currently in use with one which
  * contains custom IDS events designed specifically for this UnitTestCase.
  */
 protected function setUp()
 {
     $this->_restoreSecCon = ESAPI::getSecurityConfiguration();
     ESAPI::setSecurityConfiguration(null);
     // Use a custom properties file.
     $sc = ESAPI::getSecurityConfiguration(__DIR__ . '/../testresources/ESAPI_IDS_Tests.xml');
     $this->_logFileLoc = getLogFileLoc();
     $this->_logDateFormat = $sc->getLogFileDateFormat();
 }
 /**
  * Constructor swaps the SecurityConfiguration currently in use with one which
  * contains custom IDS events designed specifically for this UnitTestCase.
  *
  * @return null
  */
 function __construct()
 {
     global $ESAPI;
     if (!isset($ESAPI)) {
         $ESAPI = new ESAPI(dirname(__FILE__) . '/../testresources/ESAPI.xml');
     }
     $this->_restoreSecCon = ESAPI::getSecurityConfiguration();
     ESAPI::setSecurityConfiguration(null);
     // Use a custom properties file.
     $sc = ESAPI::getSecurityConfiguration(dirname(__FILE__) . '/../testresources/ESAPI_IDS_Tests.xml');
     $this->_logFileLoc = getLogFileLoc();
     $this->_logDateFormat = $sc->getLogFileDateFormat();
 }
Ejemplo n.º 3
0
 protected function setUp()
 {
     $this->logFileLoc = getLogFileLoc();
     $this->testLogger = ESAPI::getAuditor(__CLASS__);
     $this->testLogger->setLevel(Auditor::ALL);
 }
Ejemplo n.º 4
0
 function __construct()
 {
     ESAPI::getEncoder();
     $this->logFileLoc = getLogFileLoc();
 }