Improved database version check so tests run correctly on MariaDB 10.