code: def test_successor(self):
      assert dict(nx.bfs_successors(self.G, source=0)) == {
          0: [1],
          1: [2, 3],
          2: [4],
      }
  
imports: from functools import partial
  import pytest
  import networkx
label_desc: Use image node_id 2 for calling the TestBFS obj's underlying member method code with example usage: obj.test_successor() without return types