code: def test_notebook_button_counts(renderer_notebook, brain_gc, nbexec):
      """Test button counts."""
      from ipywidgets import Button
  
      import mne
  
      mne.viz.set_3d_backend("notebook")
      rend = mne.viz.create_3d_figure(size=(100, 100), scene=False)
      fig = rend.scene()
      mne.viz.set_3d_title(fig, "Notebook testing")
      mne.viz.set_3d_view(fig, 200, 70, focalpoint=[0, 0, 0])
      assert fig.display is None
      rend.show()
      total_number_of_buttons = sum(
          "_field" not in k for k in rend.actions.keys()
      )
      number_of_buttons = 0
      for action in rend.actions.values():
          widget = action._action
          if isinstance(widget, Button):
              widget.click()
              number_of_buttons += 1
      assert number_of_buttons == total_number_of_buttons
      assert fig.display is not None
  
imports: import pytest
  from mne.datasets import testing
label_desc: Use image node_id 3 for calling a global function with example usage: test_notebook_button_counts(renderer_notebook, brain_gc, nbexec) without return types