code: def test_in() -> None:
      res = list(
          q.find(plot.references(), dict(name={q.IN: ["a", "b"]}))
      )
      assert len(res) == 0
  
      res = list(
          q.find(
              plot.references(), dict(name={q.IN: ["a", "myscatter"]})
          )
      )
      assert len(res) == 1
  
      res = list(
          q.find(
              plot.references(),
              dict(name={q.IN: ["a", "myscatter", "myline"]}),
          )
      )
      assert len(res) == 2
  
      res = list(
          q.find(
              plot.references(),
              dict(name={q.IN: ["a", "myscatter", "myline", "myrect"]}),
          )
      )
      assert len(res) == 3
  
      for typ, count in typcases.items():
          res = list(
              q.find(plot.references(), dict(type={q.IN: [typ]}))
          )
          assert len(res) == count
          assert all(isinstance(x, typ) for x in res)
  
          res = list(
              q.find(plot.references(), dict(type={q.IN: [typ, dict]}))
          )
          assert len(res) == count
          assert all(isinstance(x, typ) for x in res)
  
          res = list(
              q.find(plot.references(), dict(type={q.IN: [dict]}))
          )
          assert len(res) == 0
  
      # count adjusted by hand to account for duplicates/subclasses
      res = list(
          q.find(
              plot.references(),
              dict(type={q.IN: list(typcases.keys())}),
          )
      )
      assert len(res) == 17
  
file_path: bokeh/tests/unit/bokeh/core/test_query.py
imports: from __future__ import annotations
  import pytest
  from bokeh.models import Axis, BoxZoomTool, ColumnDataSource, DatetimeAxis, Glyph, GlyphRenderer, Grid, Line, LinearAxis, LogAxis, PanTool, Plot, Range1d, Rect, ResetTool, SaveTool, Scatter, Tool, WheelZoomTool
  import bokeh.core.query
label_desc: Use image node_id 7 for calling a global function with example usage: test_in() without return types