MDL-68780 unit tests: Add missing ->destroy() calls to controllers
authorEloy Lafuente (stronk7) <stronk7@moodle.org>
Tue, 19 May 2020 21:48:13 +0000 (23:48 +0200)
committerEloy Lafuente (stronk7) <stronk7@moodle.org>
Wed, 20 May 2020 09:02:00 +0000 (11:02 +0200)
commit5b188629c7f001ad8207c374a875bf50d86abd85
treead36eb562a7d32243e495775ee1b15d5a42a040e
parent1afe68f3820b2b5996aa313357e3ddd3d5890192
MDL-68780 unit tests: Add missing ->destroy() calls to controllers

Every backup and restore controller always need to call
to their ->destroy() method in charge of finalizing loggers,
closing file handlers and destroy some circular references.

This is specially important within unit tests, because
open resources cannot be reset between tests, causing problems,
specially within Windows that locks all those files.
backup/util/helper/tests/async_helper_test.php