While there is only a single .php file with 2 hook handlers it looks like it's complex enough to be worth having a few PHPUnit tests.
It might be necessary to rewrite the code first to make it better testable. Please aim for a pure MediaWikiUnitTestCase test, if possible!