MDL-80844 phpunit: Only some tests can use the debugging sink
commit6e2c5b7b45369e6730ac3b5d686c421c0d3f3fd7
authorEloy Lafuente (stronk7) <stronk7@moodle.org>
Tue, 6 Feb 2024 13:52:07 +0000 (6 14:52 +0100)
committerEloy Lafuente (stronk7) <stronk7@moodle.org>
Thu, 15 Feb 2024 17:46:16 +0000 (15 18:46 +0100)
tree51dc696fdc3b358a34a38c9f56fa499f2ba9b1e3
parentd3ad77e4762ee5b96a3fecb51158c6039202f39e
MDL-80844 phpunit: Only some tests can use the debugging sink

The only tests that have COMPLETE* support for the debugging sink
are the advanced_testcase and the database_driver ones (store and
report). So we must ensure that the rest of tests don't use the
debugging sink at all.

Right now we are using it for storing, but later there is not
reporting, so any debugging happening within non advanced tests
is not detected.

This commit just ensures that we stop making that storing for
non advanced/database_driver tests. Nothing more, nothing less.

* Note that we have had to add a few missing bits to the
database_driver testcase because it was not 100% complete. Now
it behaves 100% the same than the advanced_testcase one regarding
the debugging sink.
lib/phpunit/classes/database_driver_testcase.php
lib/phpunit/classes/util.php