Commit 1a22d8d5 authored by Dan Poltawski's avatar Dan Poltawski Committed by Eloy Lafuente
Browse files

Merge branch 'wip-mdl-58169' of https://github.com/rajeshtaneja/moodle

parents 594ada13 dba39da0
......@@ -288,6 +288,20 @@ class cache_config_testing extends cache_config_writer {
global $CFG;
return $CFG->wwwroot.'phpunit';
}
/**
* Checks if the configuration file exists.
*
* @return bool True if it exists
*/
public static function config_file_exists() {
// Allow for late static binding by using static.
$configfilepath = static::get_config_file_path();
// Invalidate opcode php cache, so we get correct status of file.
core_component::invalidate_opcode_php_cache($configfilepath);
return file_exists($configfilepath);
}
}
/**
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment