code: def test_SequenceDB(self):
      seq_db = SequenceDB(failure_callback=None)
  
      res = seq_db.query("+a")
  
      assert isinstance(res, SequentialGraphRewriter)
      assert res.data == []
  
      seq_db.register("b", TestRewriter(), position=1)
  
      from io import StringIO
  
      out_file = StringIO()
      seq_db.print_summary(stream=out_file)
  
      res = out_file.getvalue()
  
      assert str(id(seq_db)) in res
      assert "names {'b'}" in res
  
      with pytest.raises(TypeError, match=r"`position` must be.*"):
          seq_db.register("c", TestRewriter(), position=object())
  
file_path: pytensor/tests/graph/rewriting/test_db.py
imports: import pytest
  from pytensor.graph.rewriting.basic import GraphRewriter, SequentialGraphRewriter
  from pytensor.graph.rewriting.db import EquilibriumDB, LocalGroupDB, ProxyDB, RewriteDatabase, SequenceDB
label_desc: Use image node_id 3 for calling the TestDB obj's underlying member method code with example usage: obj.test_SequenceDB() without return types