Ejemplo n.º 1
0
def backends(request):
    from caproto import select_backend, backend

    def switch_back():
        select_backend(initial_backend)

    initial_backend = backend.backend_name
    request.addfinalizer(switch_back)

    try:
        select_backend(request.param)
    except KeyError:
        raise pytest.skip(f'backend {request.param} unavailable')
Ejemplo n.º 2
0
 def switch_back():
     select_backend(initial_backend)