Beispiel #1
0
 public static function __callstatic($name, $args)
 {
     if (ezcBase::getRunMode() == ezcBase::MODE_DEVELOPMENT) {
         return call_user_func_array(array(self::$ezcDebugInstance, $name), $args);
     } else {
         return null;
     }
 }
Beispiel #2
0
 public function testSetGetRunMode()
 {
     self::assertEquals(ezcBase::MODE_DEVELOPMENT, ezcBase::getRunMode());
     self::assertEquals(true, ezcBase::inDevMode());
     ezcBase::setRunMode(ezcBase::MODE_PRODUCTION);
     self::assertEquals(ezcBase::MODE_PRODUCTION, ezcBase::getRunMode());
     self::assertEquals(false, ezcBase::inDevMode());
     ezcBase::setRunMode(ezcBase::MODE_DEVELOPMENT);
     self::assertEquals(ezcBase::MODE_DEVELOPMENT, ezcBase::getRunMode());
     self::assertEquals(true, ezcBase::inDevMode());
 }