[ticket/12743] Make sure to use up-to-date schema with extensions

The database test case will not load the schema again if the database is
already connected. If an extension adds schema changes and a database test
case without those is run before, the database schema will not contain tables
and columns the extension might add.

PHPBB3-12743

Ticket: https://tracker.phpbb.com/browse/PHPBB3-12743
Can we compare the current extension set to the last one, so we do not create too many unnecessary connections.

Also you should close the current connection?