/** * Performs all "ExpensiveCheck" methods. Note that this is usually * invoked in the Configuration check screen and therefore any * errors set here are "non-lethal", i.e. the application still works * although certain features may not function properly. */ public static function performExpensive() { self::$opa_error_messages = array(); self::$opo_db = new Db(); self::$opo_config = ConfigurationCheck::$opo_db->getConfig(); /* execute checks */ $vo_reflection = new ReflectionClass("ConfigurationCheck"); $va_methods = $vo_reflection->getMethods(); foreach ($va_methods as $vo_method) { if (strpos($vo_method->name, "ExpensiveCheck") !== false) { if (!$vo_method->invoke("ConfigurationCheck")) { // true means keep on doing checks; false means stop performing checks return; } } } }
/** * Invokes an explicit list of tests to be executed before * CollectiveAccess installation */ public static function performInstall() { self::$opa_error_messages = array(); self::$opo_db = new Db(); self::$opo_config = ConfigurationCheck::$opo_db->getConfig(); self::PHPVersionQuickCheck(); self::PHPModuleRequirementQuickCheck(); self::memoryLimitExpensiveCheck(); self::DBInnoDBQuickCheck(); self::permissionInstallCheck(); self::DBLoginQuickCheck(); self::tmpDirQuickCheck(); }