'Create a fresh DB and run all migrations on it.'

def test_sync_db(self, version=None):

    self.initialize_test_db()
    try:
        logging.info('Starting    migration    test    on    DB    %s', self.get_db_name())
        self.migrate_to_version_or_latest(version)
        utils.system(('mysqldump    %s    --no-data=true    --add-drop-table=false' % self.get_mysql_args()), ignore_status=True)
        logging.info('Test    finished    successfully')
    finally:
        self.remove_test_db()
