def test_qs_load(): logger.debug('test_qs_load') hutch_python.qs_load.QSBackend = QSBackend objs = get_qs_objs('LR12', '15') assert objs['inj_x'].run == '15' assert objs['inj_x'].proposal == 'LR12' assert objs['inj_x'].kerberos == 'True' # Check that we can handle an empty Questionnaire QSBackend.empty = True assert get_qs_objs('LR12', '15') == dict() QSBackend.empty = False
def test_qs_load(fake_qsbackend): logger.debug('test_qs_load') clear_happi_cache() objs = get_qs_objs('tstlr1215') assert objs['inj_x'].run == '15' assert objs['inj_x'].proposal == 'LR12' assert objs['inj_x'].kerberos == 'True' # Check that we can handle an empty Questionnaire fake_qsbackend.empty = True assert get_qs_objs('tstlr1215') == dict() fake_qsbackend.empty = False
def test_ws_auth_conf(temporary_config, fake_qsbackend): logger.debug('test_ws_auth_conf') clear_happi_cache() objs = get_qs_objs('tstlr1215') assert objs['inj_x'].kerberos == 'False' assert objs['inj_x'].user == 'user' assert objs['inj_x'].pw == 'pw'
def test_ws_auth_conf(temporary_config): logger.debug('test_ws_auth_conf') hutch_python.qs_load.QSBackend = QSBackend clear_happi_cache() objs = get_qs_objs('LR12', '15') assert objs['inj_x'].kerberos == 'False' assert objs['inj_x'].user == 'user' assert objs['inj_x'].pw == 'pw'