code: def test_single_cell_picking():
      sphere = pv.Sphere()
      width, height = 100, 100
  
      class PickCallback:
          def __init__(self):
              self.called = False
  
          def __call__(self, *args, **kwargs):
              self.called = True
  
      plotter = pv.Plotter(
          window_size=(width, height),
      )
  
      callback = PickCallback()
      plotter.enable_cell_picking(
          start=False,
          show=True,
          callback=callback,
          through=False,  # Single cell visible picking
      )
      plotter.add_mesh(sphere)
      plotter.show(auto_close=False)  # must start renderer first
  
      width, height = plotter.window_size
      plotter.iren._mouse_move(width // 2, height // 2)
      plotter.iren._simulate_keypress("p")
  
      plotter.close()
  
      assert callback.called
      assert isinstance(plotter.picked_cells, pv.UnstructuredGrid)
      assert plotter.picked_cells.n_cells == 1
  
imports: import os
  import numpy
  import pytest
  import vtk
  import pyvista
  from pyvista.plotting.errors import PyVistaPickingError
label_desc: Use image node_id 1 for calling a global function with example usage: test_single_cell_picking() without return types