Example #1
0
def browser_backend(request, garbage_collect):
    """Parametrizes the name of the browser backend."""
    backend_name = request.param
    if backend_name == 'pyqtgraph':
        _check_pyqtgraph()
    with use_browser_backend(backend_name) as backend:
        yield backend
        backend._close_all()
Example #2
0
def pg_backend(request, garbage_collect):
    """Use for pyqtgraph-specific test-functions."""
    _check_pyqtgraph(request)
    with use_browser_backend('qt') as backend:
        backend._close_all()
        yield backend
        backend._close_all()
        # This shouldn't be necessary, but let's make sure nothing is stale
        import mne_qt_browser
        mne_qt_browser._browser_instances.clear()
Example #3
0
def browser_backend(request, garbage_collect):
    """Parametrizes the name of the browser backend."""
    backend_name = request.param
    if backend_name == 'qt':
        _check_pyqtgraph(request)
    with use_browser_backend(backend_name) as backend:
        backend._close_all()
        yield backend
        backend._close_all()
        if backend_name == 'qt':
            # This shouldn't be necessary, but let's make sure nothing is stale
            import mne_qt_browser
            mne_qt_browser._browser_instances.clear()
Example #4
0
def mpl_backend(garbage_collect):
    """Use for epochs/ica when not implemented with pyqtgraph yet."""
    with use_browser_backend('matplotlib') as backend:
        yield backend
        backend._close_all()
Example #5
0
def browse_backend(request, garbage_collect):
    """Parametrizes the name of the browser backend."""
    with use_browser_backend(request.param) as backend:
        yield backend
Example #6
0
def pg_backend(garbage_collect):
    """Use for pyqtgraph-specific test-functions."""
    _check_pyqtgraph()
    with use_browser_backend('pyqtgraph') as backend:
        yield backend
        backend._close_all()