-
Bug
-
Resolution: Fixed
-
Minor
-
3.7
-
MOODLE_37_STABLE
-
MOODLE_37_STABLE
-
While running phpunit tests under Windows to complete the 3.7 release testing matrix it has been detected that, from a point, all test start to fail with "Invalid permissions/files locked" problems.
Tracing down the problem, it seems that some backup tests (at very least) are not properly destroying the backup/restore controllers. That leaves files (logs, temps...) not closed.
While that's not a problem in unix... under windows that leads to files locked so they cannot be removed as part of the standard reset process between tests, causing ALL them to fail.
This issue is about to detect all the places where we are leaving controllers not explicitly destroyed and proceed to do it.
Note: To reproduce this properly, ideally you should update your phpunit to current 7.5.8 or higher. There is a bug in 7.5.7 making this bug unintelligible. See linked issues.