mirror of
https://github.com/moodle/moodle.git
synced 2025-04-21 16:32:18 +02:00
Merge branch 'MDL-80862-401' of https://github.com/andrewnicols/moodle into MOODLE_401_STABLE
This commit is contained in:
commit
58ba1a9448
@ -432,6 +432,9 @@ class behat_util extends testing_util {
|
||||
// Inform data generator.
|
||||
self::get_data_generator()->reset();
|
||||
|
||||
// Reset the task manager.
|
||||
\core\task\manager::reset_state();
|
||||
|
||||
// Initialise $CFG with default values. This is needed for behat cli process, so we don't have modified
|
||||
// $CFG values from the old run. @see set_config.
|
||||
self::remove_added_config();
|
||||
|
@ -61,6 +61,15 @@ class manager {
|
||||
*/
|
||||
public static $mode;
|
||||
|
||||
/**
|
||||
* Reset the state of the task manager.
|
||||
*/
|
||||
public static function reset_state(): void {
|
||||
self::$miniqueue = null;
|
||||
self::$numtasks = null;
|
||||
self::$mode = null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Given a component name, will load the list of tasks in the db/tasks.php file for that component.
|
||||
*
|
||||
|
Loading…
x
Reference in New Issue
Block a user