import os
import json


def _get_test_db():
    db_json = os.getenv('TEST_DB_CONFIG', None)
    if db_json:
        with open(db_json, 'r') as f:
            return json.load(f)
    else:
        return {
            'base_url': 'https://test.alyx.internationalbrainlab.org',
            'username': 'test_user',
            'password': 'TapetesBloc18',
            'silent': True
        }


TEST_DB = _get_test_db()
